Weeding out duplicate values (using DISTINCT)
Posted on 2005-05-12
Environment: MS SQL Server 2000
Say I have a table like the following:
'SELECT DISTINCT userid, colour, flavour' blocks the display of row 4 (since every element in that row was already returned with row 3), but not row 2 (since the flavour value differs). How do I return only one row per userid value?
I haven't found any working examples of DISTINCT ORDER BY (which sounds like it would be useful).
Thanks in advance,