Thanks Tripy. I always have a hell of a time when I alias something and need to refer to it. Never had a chance to formally study DB's and SQL in college. Have just hacked my way through MySQL (but, to be fair, I don't do bad hacking MySQL's language structure  ).
EDIT: Oh, I added a primary key field so that the results can be cross-referenced.
DOUBLE-EDIT: Ah, but the primary key won't work there because of the grouping you suggest, so one would need to select the field being grouped on too, right?
__________________
Jeremy Miller
Please login or register to view this content. Registration is FREE
Last edited by JeremyMiller; 08-05-2008 at 09:56 PM..
|