Ticket Hash: | 1ab48697a5b0297aafcbaa30e064377aafc57fde | |||
Title: | LINQ method "String.Contains" when convert to SQL will generate CHARINDEX instead of LIKE, this may cause wrong result in Chinese character. | |||
Status: | Closed | Type: | Incident | |
Severity: | Important | Priority: | Medium | |
Subsystem: | LINQ | Resolution: | Not_Backwards_Compatible | |
Last Modified: | 2018-04-26 16:42:52 | |||
Version Found In: | 1.0.102 | |||
User Comments: | ||||
anonymous added on 2017-03-02 10:06:25:
(text/x-fossil-plain)
LINQ method "String.Contains" when convert to SQL will generate CHARINDEX instead of LIKE, this may cause wrong result in Chinese character. The result will not only show records contains keyword, but also show records not contains keyword. In some sqlite gui query tools, using LIKE to query records will get the right result. And there is no method called CHARINDEX. By look into source, maybe because CHARINDEX is not considered for utf-8 character. I think maybe can change CHARINDEX method to support utf-8, or convert String.Contains to like in SQL. My English is not good, hope you can understand what I say. Thanks a lot! For example: “无敌” and “承担” seems the same in charindex. mistachkin added on 2017-04-03 23:27:20: (text/x-fossil-plain) This issue will not block the 1.0.105.0 release. |