LIKE without a wildcard |
[eluser]Cheater[/eluser]
http://codeigniter.com/bug_tracker/bug/8152/ Can someone confirm that that bug report is correct? It is where you are trying to do a SQL LIKE query, without any wildcards. CodeIgniter cannot currently do that. It must insert a wildcard. Its needed when want to do a case-insensitive search in MySQL.
[eluser]davidbehler[/eluser]
Can't you use Code: LCASE(col_1) = LCASE('abc') Code: col_1 LIKE 'abc' Should be the same, or not?
[eluser]Cheater[/eluser]
Functionality wise yes its equivalent, but worse performance wise. LIKE 'abc' uses indexes for a case insensitive search while LCASE would require to make every individual row lower case and then do the comparison.
[eluser]davidbehler[/eluser]
Ok, performance wise it suxx..you are right. But those out there that don't want to edit core files could use that solution until the "bug" is fixed/the missing feature is added. |
Welcome Guest, Not a member yet? Register Sign In |