Querying two tables

From: Date: Sat, 14 Dec 2002 23:14:12 +0000
Subject: Querying two tables
Groups: php.general 
Request: Send a blank email to php-general+get-128304@lists.php.net to get a copy of this message
Hi all, I have several tables from which I have to fetch certain products & categories based on customer selection. The tables are as follows: Table 1 - Categories catid (autonum) catname Table 2 - Sub categories subcatid (autonum) subcatname Table 3 - Products prodid (autonum) prodname Table 4 - Relationships Catid Subcatid Prodid Now, the question is how to fetch all the sub-categories let's say that are related to category 0001. I know it's as simple as relating two tables in one query, but I don't remember how. Any help appreciated. Cesar L. Aracena icaam@icaam.com.ar caracena@infovia.com.ar (0299) 156-356688 Neuquén (8300) Capital Argentina

« previous php.general (#128304) next »