|
|
scott wrote:
> So I take it using SELECT DISTINCT X ... is better than using SELECT X
> ... GROUP BY X for what I want to do?
I don't know. I'd say it's more "correct" in some abstract theoretical
sense, since the only reason you're grouping is to get unique rows. And it
works in the case you're trying. :-)
If you wanted to know how many different types of events each experiment
yielded, you'd do something like
select expid, count(eventid) from exp group by expid
or something like that. (Not gonna fire up SQL to try it.)
But you see what I'm saying there.
--
Darren New, San Diego CA, USA (PST)
My fortune cookie said, "You will soon be
unable to read this, even at arm's length."
Post a reply to this message
|
|