Search for existing suggestions

Collation support

Currently strings are compared via default database collation or column collation when the comparison is translated to SQL. But they are compared to be binary equal when the code is executed in CLR.

So adding .ToList() before .Select() may suddenly change the result of comparison. And the tests with mocked IQueryables also work differently from the database translated queries.

Also it's sometimes required to compare strings using different collation. Currently that's only possible if you load the entire data into memory first and compare in CLR. However, even that case is troubling since there is no exact equivalent of SQL collations in .NET.

I propose to add methods that allow to compare values via different collations. And make the method not only translatable to SQL but also executable in CLR.

2 votes
Sign in
(thinking…)
Sign in with: facebook google
Signed in as (Sign out)

We’ll send you updates on this idea

Ihar Bury shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

0 comments

Sign in
(thinking…)
Sign in with: facebook google
Signed in as (Sign out)
Submitting...

Feedback and Knowledge Base