Hi,
I want to select reocrds from a mySQL table, but I only want records that are unique, e.g.
table looks like
1 nathan 2 nathan 3 nathan 4 bob 5 bob 6 nathan 7 nathan
I want the output to be:
1 nathan 4 bob
any ideas?
This question was answered twice a few days back. Did you search?
SELECT column2, count() FROM table GROUP BY column2 HAVING count() = 1
Thanks Vincent.
I did search but I was thinking along different lines and didn't find anything quite right.
Did you get it to do what you want now?
Thanks, it works a treat.
Cool, another happy customer :-)
If you just want the names try
SELECT DISTINCT name FROM table
You should read the rest of the thread.