moisesbr Posted August 18, 2013 Share Posted August 18, 2013 Hi How to ignore upper/lower case why searching ? e.g.: Locate a name in database where search term = two first letters of string"MA" results Mark ou mark or "ma" results Mark ou mark Also, do I need to trim A string as in some languages if user mistype a space: " MA" Moises Quote Link to comment Share on other sites More sharing options...
requinix Posted August 18, 2013 Share Posted August 18, 2013 What's the collation of the field you're searching on? If you don't know, what does SHOW CREATE TABLE output for it? Quote Link to comment Share on other sites More sharing options...
moisesbr Posted August 18, 2013 Author Share Posted August 18, 2013 What's the collation of the field you're searching on? If you don't know, what does SHOW CREATE TABLE output for it? Hi It's: utf8_general_cl Quote Link to comment Share on other sites More sharing options...
requinix Posted August 19, 2013 Share Posted August 19, 2013 Then I don't see why it wouldn't be searching case-insensitively already. The space probably matters - strip it out for good measure. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.