Re: Sub selects working around

2001-01-16 Thread Jan Dvorak
Hi Eric, I'll second Bob Hall's opinion. One could extend a query so that it checks also your additional condition. You haven't gotten to the 'group by' and 'having' goodies, that's the hint. But this would make it over-complicated, and MySQL could run into problems when attempting to evaluate t

Re: Sub selects working around

2001-01-16 Thread Bob Hall
Sir, here's a guess in return. The best way to deal with this is to have your client app run a query that counts the rows where packagesParts.pri <> 0. Then run the query below only if the count is greater than 0. Bob Hall >Hi, > >I am guessing this is the kind of problem that would be easier

Sub selects working around

2001-01-16 Thread Eric Frazier
Hi, I am guessing this is the kind of problem that would be easier to solve with a sub select SELECT simpleparts.category,simpleparts.partnumber,simpleparts.manufacturer,simplep arts.descrp,ABS(packagesParts.pri) as abPRI,categories.sortorder FROM ((packagenames LEFT JOIN packagesParts ON packa

Sub selects working around

2001-01-14 Thread Eric Frazier
Hi, I am guessing this is the kind of problem that would be easier to solve with a sub select SELECT simpleparts.category,simpleparts.partnumber,simpleparts.manufacturer,simplep arts.descrp,ABS(packagesParts.pri) as abPRI,categories.sortorder FROM ((packagenames LEFT JOIN packagesParts ON packa