[Salesforce] Excepction during execute simple query.

Discussion of open issues, suggestions and bugs regarding Entity Framework support in ADO.NET Data providers
Post Reply
cargt3
Posts: 3
Joined: Mon 24 Jun 2019 14:47

[Salesforce] Excepction during execute simple query.

Post by cargt3 » Mon 24 Jun 2019 15:00

Hi,

I have simple linq query which use entity framework for salesforce.

Code: Select all

            var contex = new ModelContext();
            var aaaa = contex.Account.Where(x => x.Id == "0011l00000GNHtSAAX").ToList();
During execution i get error:

Code: Select all

Devart.Data.Salesforce.SalesforceException: 'You have an error in your SQL syntax at line 3, column 22: Unexpected symbol 'l00000GNHtSAAX'.'
I see that id is somehow cut to first letter l but i dont know how to fix it.

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Re: [Salesforce] Excepction during execute simple query.

Post by Shalex » Wed 26 Jun 2019 19:58

We cannot reproduce the issue at the moment. Please tell us:

1) the version (x.x.x) of your dotConnect for Salesforce

2) the EF version (e.g.: EF6)

3) enable dbMonitor and specify the generated SQL

cargt3
Posts: 3
Joined: Mon 24 Jun 2019 14:47

Re: [Salesforce] Excepction during execute simple query.

Post by cargt3 » Mon 01 Jul 2019 14:15

1) 3.0.17.0
2) EF Core 2
3) For id = 0016E00000r6RIbQAM query its not generated . For id = E00000r6RIbQAM its generate (I remove unnecessary fields from select):

Code: Select all

SELECT "x"."Id"
FROM "Account" AS "x"
WHERE "x"."Id" = r6RIbQAM
but in c# i get error "Unknown column 'E00000r6RIbQAM". Its look like quotas are missing.

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Re: [Salesforce] Excepction during execute simple query.

Post by Shalex » Wed 03 Jul 2019 19:20

Thank you for your report. We have reproduced the issue and are investigating it.

cargt3
Posts: 3
Joined: Mon 24 Jun 2019 14:47

Re: [Salesforce] Excepction during execute simple query.

Post by cargt3 » Thu 04 Jul 2019 07:01

Is any bypass exits for this problem like changing version of dotConnect or EF? I'm checking is dotConnect fits requirement of my company and i dont have many days of trial left.

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Re: [Salesforce] Excepction during execute simple query.

Post by Shalex » Thu 04 Jul 2019 19:12

We have fixed the issue. A trial build with the fix is available at https://www.dropbox.com/s/mxsh70awbo5hf ... l.exe?dl=0.

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Re: [Salesforce] Excepction during execute simple query.

Post by Shalex » Thu 25 Jul 2019 14:40

New public build of dotConnect for Salesforce 3.4.805 is available for download.

Post Reply