StartsWith...

Discussion of open issues, suggestions and bugs regarding Entity Framework support in ADO.NET Data providers
Post Reply
damon.cognito
Posts: 50
Joined: Wed 22 Jul 2009 09:30

StartsWith...

Post by damon.cognito » Thu 17 Sep 2009 09:44

When using StartsWith, the resultant SQL uses position which means an index is not used. This makes what should be a lightening quick search very slow. Is this just another Entities quirk that it is not using like '$1%'?

Code: Select all

clientName.TblAddresses.Line1.ToUpper().StartsWith(address.ToUpper())

Code: Select all

WHERE (position(upper($1) in upper("Extent2"."Line1"))) = 1
[/code]

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Fri 18 Sep 2009 08:36

Thank you for the report, we will investigate the situation.
I will let you know about the results.

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Wed 23 Sep 2009 08:01

We have increased the performance of the StartsWith, EndsWith and Contains methods.

damon.cognito
Posts: 50
Joined: Wed 22 Jul 2009 09:30

Post by damon.cognito » Thu 24 Sep 2009 09:10

That's great news, thanks. I have been impressed by the speed you answer/correct things.

Have you got a release date in mind please?

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Thu 24 Sep 2009 14:00

The new build is available.

damon.cognito
Posts: 50
Joined: Wed 22 Jul 2009 09:30

Post by damon.cognito » Mon 28 Sep 2009 09:12

Thank you - it works perfectly!

Post Reply