| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> c.d.o.misc -> How can i force a 0 in a SQL query?
Hi experts,
In a sql query like this:
select group_client, count(*)
from client_bills
where bill like '1000%'
group by group_client
I just get in the output, the group_client that acomplish the condition
bill like '1000%'.
But what i need is to get all group_client and force a 0 to all other
groups that don't acomplish the condition.
I'v tried nvl() and decode() but nothing works.
Some help will be greattly appreciated
Thanks in advance
Regards
Miguel Pinto
Received on Wed Jan 27 1999 - 06:57:37 CST
![]() |
![]() |