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 depending on condition - Oracle

688373Apr 10 2009 — edited Apr 10 2009
I want to count only rows which satisfy a particular condition.

I have several conditions but it needs to be one query. How would I do that?
ex:


select
count (no of days) where sales where below 100
count (no of days) where no of customers were below 100
from products
join customers
join sales
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 8 2009
Added on Apr 10 2009
1 comment
12,166 views