Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

COUNT returning 0 on GROUP BY

844611df-4db3-45a4-a3a4-798c2b83f602May 11 2016 — edited May 12 2016

Hello Experts,

   I have the below query. It works fine, but the results does not show the rows which have count as zero. Could you please review and help me re-write this query so that those profnames whose count is zero is also displayed.

select a.profname as Names, count(b.devid) as ESTIMATED_COUNT from EMS_PROF a, EMS_DEVICE b, EMS_DEVICE2PROF c where b.DEVID=c.DEVID and c.PROFID=a.PROFID group by a.profname;

Thanks,

Addy

This post has been answered by BrunoVroman on May 11 2016
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 9 2016
Added on May 11 2016
6 comments
3,437 views