tallberg Posted October 20, 2006 Share Posted October 20, 2006 Can some one please describe to me the difference between these 2 queries. The first one produces 9,658 rows and second on 314 rows. I don't know what the difference is.SELECT * FROM `plantsdb` WHERE Colour_Foliage LIKE '%blue%'OR Colour_Foliage LIKE '%green%'SELECT * FROM `plantsdb` WHERE Colour_Foliage LIKE '%blue%'OR '%green%' Quote Link to comment Share on other sites More sharing options...
fenway Posted October 20, 2006 Share Posted October 20, 2006 The first query is correct... the second query is simply evaluating '%green%' as being true on some random field, having nothing to do with Colour_Foliage, and is returning garbage. 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.