pagegen Posted February 3, 2010 Share Posted February 3, 2010 SELECT * FROM clients WHERE (postcode LIKE 'm12%' OR town LIKE 'm12%') OR (postcode LIKE ' m13%' OR town LIKE ' m13%') Hi guys, am running the above query.. the problem is, its only returning the m12 address and not the m13 any suggestions? Quote Link to comment https://forums.phpfreaks.com/topic/190842-multipe-select/ Share on other sites More sharing options...
taquitosensei Posted February 3, 2010 Share Posted February 3, 2010 you've got extra spaces after the single quotes. (postcode LIKE ' m13%' OR town LIKE ' m13%') vs (postcode LIKE 'm13%' OR town LIKE 'm13%') Quote Link to comment https://forums.phpfreaks.com/topic/190842-multipe-select/#findComment-1006401 Share on other sites More sharing options...
pagegen Posted February 3, 2010 Author Share Posted February 3, 2010 Thanks pal.. solved Quote Link to comment https://forums.phpfreaks.com/topic/190842-multipe-select/#findComment-1006411 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.