I'm trying to get results back from an sql query in the easiest way to
handle in my script.
table 'categories' and table 'restcat' (restaurant categories).
I'd like to construct a query where I can look up a specific restaurant
id, yet somehow related it to the categories table so that instead of a
regular select/where, I get back something like:
+------------+----------+----------+
| restaurant | category | category |
+------------+----------+----------+
| 136 | Chinese | NULL |
| 136 | French | NULL |
| 136 | Italian | Italian |
| 136 | Pizza | Pizza |
| 136 | Seafood | NULL |
+------------+----------+----------+
Showing in this fashion that restaurant 136 is a member of the Italian
and Pizza categories but not a member of the other categories.
(and yes, my categories table actually uses category numbers)
Thanx for any help!
--
Andy
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php