>>>>>>>>>>>
Like doesn't distinguish between words, it just matches patterns.
Your first query didn't match because "work" does not match "Why this does
not work" and you didn't use wildcards.
Your second query worked because you used a wildcard so "Why this does not
work" matches /ANYTHING/ + 'work'
If you want to search for specific words in a string try:
SELECT " String of words " LIKE " words ";
by adding spaces around your search term and around your string you can
match whole words. This is pretty basic and may not be what you're trying
to do, but I hope this helps.
Chris
>>>>>>>>>>>>>>>>>>>>>>>>>>>
Here is the example of what I'm traying to do:
mysql> SELECT "Why this does not work" LIKE "work";
+-------------------------------------------------------+
| "Why this does not work" LIKE "work" |
+-------------------------------------------------------+
|
0 |
+-------------------------------------------------------+
and this works
mysql> SELECT "Why this does not work" LIKE "%work";
+----------------------------------------------------------+
| "Why this does not work" LIKE "%work" |
+----------------------------------------------------------+
|
1 |
+----------------------------------------------------------+
Why LIKE does't recognize word "work" at the end of the row when it's a
separate word
Sorry for bad english
Any help would be appriciated
---------------------------------------------------------------------
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