Thanks Tommy, Damn. I was hoping to avoid that and get all the information in one query rather than running a ton of queries. :-( But might be why I am having trouble finding an answer for this on the net. Blessed Be Phillip If you try to protect idiots from themselves, even if you succeed, you just wind up filling the world with idiots. - - Doug Casey On Mon, Jul 12, 2010 at 1:37 PM, Tommy Pham <tommyhp2@xxxxxxxxx> wrote: > > -----Original Message----- > > From: Phillip Baker [mailto:phillip@xxxxxxxxxxxx] > > Sent: Monday, July 12, 2010 11:36 AM > > To: Jim Lucas > > Cc: PHP General List > > Subject: Re: Looking for a little MySQL help as well > > > > Thanks Jim, > > > > This outputs 2 results. > > Is there a way to get the one result set per product regardless of the > number > > of categories associated with the product, yet displaying all the > categories > > associated with said prodcut? > > > > Blessed Be > > > > Phillip > > > <snip> > > Phillip, > > What you're asking for requires the use of (IIRC) 'cursors'. I don't know > if MySQL's meaning/usage of 'cursors' is the same as MSSQL. Either way, > you'll need to write some serious (read pain in the a**) Stored Procedure > (SP). You're better off implementing that in PHP loop containing 'if' > since > you're not a DBA ;). > > Regards, > Tommy > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > >