Thread mysql-Abfrag: kompliziert? Ich kriegs net hin... (4 answers)
Opened by steinwolf at 2007-02-12 20:37

pq
 2007-02-12 21:10
#35234 #35234
User since
2003-08-04
12208 Artikel
Admin1
[Homepage]
user image
[sql]SELECT c.name,c.id, count(p_id)
FROM cat c
LEFT JOIN program_cat pc ON pc.cat_id =c.id
LEFT JOIN program p ON pc.p_id =p.id
GROUP BY cat_id[/sql]
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 mysql-Abfrag: kompliziert? Ich kriegs net hin...