This is a discussion on SQL select within the PHP General forums, part of the PHP Programming Forums category; heloo, i have got a MySQL table: id_comp id_goods type cooler aa1256 n cooler aa1255 n cooler aa1317 f cooler ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
heloo,
i have got a MySQL table: id_comp id_goods type cooler aa1256 n cooler aa1255 n cooler aa1317 f cooler aa1196 n cpu cpu183 n cpu cpu177 f cpu cpu190 n gk gk1265 f gk gk1258 n gk NULL i gk gk1193 n gk gk1257 n mb mb1111 f ram mem713 n ram me1112 f ram mem704 n ram me1081 n and I need only first row of each component order by type. so: cooler aa1317 f cpu cpu177 f gk NULL i mb mb1111 f ram me1112 f has somebody some idea hot to select? jiøí nìmec, ICQ: 114651500 www.menea.cz - www stránky a aplikace |
|
|||
|
* Thus wrote Jiøí Nìmec (konference@menea.cz):
> > and I need only first row of each component order by type. so: > > cooler aa1317 f > cpu cpu177 f > gk NULL i > mb mb1111 f > ram me1112 f > > has somebody some idea hot to select? Suggestion: invest in a SQL book. Curt -- "I used to think I was indecisive, but now I'm not so sure." |