Re: help to structure query without using subselects

2003-08-01 Thread Roger Baklund
* Petre Agenbag > The distinct clause will return only one occurrance of the > implicated field. > distinctrow would do the same, but for an entire row. what I am > looking for > is something like distinctset(field1,field2,field7) , is this what the > MAX-CONCAT "trick" attempts to do? Not exactly

RE: help to structure query without using subselects

2003-08-01 Thread Petre Agenbag
head.). Thanks in any event for your time and interest. -Original Message- From: Roger Baklund [mailto:[EMAIL PROTECTED] Sent: Friday, August 01, 2003 2:49 AM To: [EMAIL PROTECTED] Cc: Petre Agenbag Subject: Re: help to structure query without using subselects * Petre Agenbag [...]

Re: help to structure query without using subselects

2003-07-31 Thread Roger Baklund
* Petre Agenbag [...] > This works: > > select distinct name, max(id) as mid from table group by name > > but it only returns the name and the highest id for such a name. > > if I try this: > > select distinct name, max(id) as mid, anything_else from table group by > name > > it returns the FIRST