Thread Select Distinct - Frage Doppeltes löschen. (2 answers)
Opened by master at 2005-06-06 15:42

pq
 2005-06-07 15:44
#33328 #33328
User since
2003-08-04
12208 Artikel
Admin1
[Homepage]
user image
[quote=renee,07.06.2005, 10:47][sql]SELECT wert, ID FROM test GROUP BY wert[/sql][/quote]
nun, dabei gehen aber IDs verloren.
probier doch mal
[sql]SELECT wert, GROUP_CONCAT(ID) AS ids, COUNT(*) AS count
 FROM test  GROUP BY wert HAVING count > 1[/sql]
oder so...
Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live. -- Damian Conway in "Perl Best Practices"
lesen: Wiki:Wie frage ich & perlintro Wiki:brian's Leitfaden für jedes Perl-Problem

View full thread Select Distinct - Frage Doppeltes löschen.