yeah
but that wont really do it since the names are in two columns
so, there must also be a UNION included
do a union and then select distinct on the result from the union
that should do it (eller hur?)

-----Ursprungligt meddelande-----
Från: Jonas Lindén [mailto:[EMAIL PROTECTED]
Skickat: den 17 februari 2004 16:01
Till: Carl Schéle; IT; Posten; [EMAIL PROTECTED]
Ämne: Re: SQL-HELP


Hello, you might want to try select DISTINCT ?

http://www.mysqlfreaks.com/statements/18.php

/Jonas

----- Original Message ----- 
From: "Carl Schéle, IT, Posten" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, February 17, 2004 3:49 PM
Subject: SQL-HELP


Hello!

I got a table, champions, looking like this:



id                   winner_1         winner_2

--------------------------------------------------------

0                    carl                 mattias

1                    daniel             carl

2                    erik                 daniel

3                    erik                 johan



What I want is to retrieve the unique names ie:



carl

mattias

daniel

erik

johan



I use MySQL 3.23.58 (which means I can't use sub-selects).



/Carl





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to