Hi!

Is there a case insensitive version of 'InStr' function in MySql ?

I need to search a database for secified substring.
This can be done by function InStr which "Returns the position of the first
occurrence of substring substr in string str".
There are also functions named: LOCATE, POSITION with exactly the same
functionality.
But this function is case sensitive, that means that when I use it in SQL
statement like this:
SELECT * FROM table WHERE instr(column,'substring')
only rows containing substring 'substring' and NOT 'Substring' are returned.
But i need to find all occurrences, so I need case insensitive version of
this function. I can do this by ... instr(lcase(column),'substring') ... but
it will be much slower.

Is there such function in MySql??

Please reply directly to my e-mail address because I'm not subscribed in the
list.

Thanx for help.

Lubo.


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to