mysql multiple word search

admin

Administrator
Staff member
I have a mysql table with a ID, a filename, and description, and searchwords.
What I'm doing now is getting a word via a form from a user and doing something like.
SELECT * FROM pic WHERE descript LIKE \"%$search%\" OR blurb LIKE \"%$search%\"

This works for one keyword, but I want users to be able to enter more then one, and I want to return all rows that have at least one match. Is there a way to do this other then a bunch of OR LIKE?

Thanks
-Mike
 
Back
Top