> I need a where clause in following situation: > > Say I want to query two tables: A and B. In table A there is field > Afn, while in table B there are 3 fields: Bfn1, Bfn2 and > Bfn3. I want > to do a query, in which the where clause must do these things: > > if A.Afn=1, then check value of B.Bfn1; > if A.Afn=2, then check value of B.Bfn2; > if A.Afn=3, then check value of B.Bfn3. > > So how can I create such a where clause to do this?
I suspect you'd be better off asking this question in a mailing list for whatever database you are using. At the very least, it would probably help to mention the database but it's still not real relevant here in this (already high volume) mailing list. CYA, Dave -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php