Won't Do
Details
Details
Assignee
Alex Zaytsev
Alex ZaytsevReporter
Hung Tran Dinh
Hung Tran DinhLabels
Components
Affects versions
Priority
Who's Looking?
Open Who's Looking?
Created September 7, 2010 at 3:18 AM
Updated June 19, 2020 at 5:40 PM
Resolved June 19, 2020 at 5:40 PM
My mapping is
LINQ:
SQL:
LINQ:
SQL:
LINQ:
=> The where clause in all cases above should be 'where order0_.[CODE] like @p0', and @p0 = '%001%' / @p0 = '001%' / @p0 = '%001' , the one will gain more performance when the query above run many times.
=> StartsWith/EndsWith/Contains methods can reuse the same SQL Execution Plan by database engine
LINQ:
SQL:
=> The where clause should be 'where length(order0_.[CODE]) >= (@p0 + @p1) and substring(order0_.[CODE], 0, 1) == 2'