$mresult = mysql_query ("select * from mates m, contact c // id, name, died, misc & id, add,ph,email,misc
where m.id = c.id
and m.passed <> 1 // not dead
and c.misc = 'returned' // smail returned
or (c.address = '' and c.phone = '' and c.email = '') // address,phone,email all blank
;")
I'm looking for classmates that we can't find. If I take out either of the last 2 lines I get what I want for what's left. If I run the query as is I get the product of the 2 tables. Or maybe I'm having a senior moment .... :-/
Thanks
where m.id = c.id
and m.passed <> 1 // not dead
and c.misc = 'returned' // smail returned
or (c.address = '' and c.phone = '' and c.email = '') // address,phone,email all blank
;")
I'm looking for classmates that we can't find. If I take out either of the last 2 lines I get what I want for what's left. If I run the query as is I get the product of the 2 tables. Or maybe I'm having a senior moment .... :-/
Thanks