-Original Message-
From: Miguel Vaz [mailto:pagong...@gmail.com]
Sent: Tuesday, December 15, 2009 10:43 AM
To: mysql@lists.mysql.com
Subject: Count records in join
Hi,
I am stuck with a suposedly simple query:
- i have two tables (:
PROGS
id_prog
name
EVENTS
id
id_prog
Subject: Count records in join
Hi,
I am stuck with a suposedly simple query:
- i have two tables (:
PROGS
id_prog
name
EVENTS
id
id_prog
name
How can i list all records from PROGS with a sum of how many events each
have? I want to find the progs that are empty.
I remember something
-Original Message-
From: Miguel Vaz [mailto:pagong...@gmail.com]
Sent: Wednesday, December 16, 2009 9:39 AM
To: Johan De Meersman
Cc: Gavin Towey; mysql@lists.mysql.com
Subject: Re: Count records in join
Thanks all for the feedback. Here's what i did:
select p.id_prog,count(r.id_event) e
:
-Original Message-
From: Miguel Vaz [mailto:pagong...@gmail.com]
Sent: Wednesday, December 16, 2009 9:39 AM
To: Johan De Meersman
Cc: Gavin Towey; mysql@lists.mysql.com
Subject: Re: Count records in join
Thanks all for the feedback. Here's what i did:
select p.id_prog,count(r.id_event
Hi,
I am stuck with a suposedly simple query:
- i have two tables (:
PROGS
id_prog
name
EVENTS
id
id_prog
name
How can i list all records from PROGS with a sum of how many events each
have? I want to find the progs that are empty.
I remember something about using NULL, but i cant remember.
[mailto:pagong...@gmail.com]
Sent: Tuesday, December 15, 2009 10:43 AM
To: mysql@lists.mysql.com
Subject: Count records in join
Hi,
I am stuck with a suposedly simple query:
- i have two tables (:
PROGS
id_prog
name
EVENTS
id
id_prog
name
How can i list all records from PROGS with a sum of how