this is very understandable:
SELECT * FROM `student` WHERE name like '%John%'
But, I am querying SQL server and wish to use an "OR" statement. I have more than one field to query.
Is this correct?
SELECT * FROM `student`
WHERE fname LIKE '%John%'
OR lname LIKE '%Smith%'
I am testing it in SQL Query analyzer and I get all records.
The OR is just a guess, and I couldn't find anything online describing how it is done.