More than 1 WHERE clause?
I need to pick selections from a table, but I have two criteria to meet and am not sure how to do it:
1) The id needs to match a variable:
"SELECT DISTINCT city_id FROM location WHERE master_id = $siteid"
2) The id needs not to be blank - some of the entries for it may be left blank, but gathering the blank entries creates an error, so I need to have a:
"...WHERE master_id != "
Is there a way that I can SELECT depending on two different WHEREs?
Thanks much!
Ben
|