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!

I have use NVL But Zero Not Dispaly in Report

VedantSep 19 2011 — edited Sep 19 2011
DEAR,

I am using sql report

code is
select INVOICE_NO,INVOICE_TYPE,INVOICE_FLAG,INVOICE_DATE,
FILE_CODE,
(select NVL(count(LINE_ID),0) from AR_INVOICE_DTL_1 AD 
where TM.INVOICE_NO=AD.INVOICE_NO GROUP BY INVOICE_NO) AS BILLNO
from AR_INVOICE_MAS TM WHERE FILE_CODE=:P7_FILE_CODE
here i have group by by invoice no.

Problem is i want to display No of line in reoport so i have use
(select NVL(count(LINE_ID),0) from AR_INVOICE_DTL_1 AD 
where TM.INVOICE_NO=AD.INVOICE_NO GROUP BY INVOICE_NO) AS BILLNO


LINE_ID is VARCHAR2(10)
but if count LINE ID is ZERO then that does not display me 0  in Report that display me Blank.
i want to display '0' where is count line id is ZERO then display in Report '0'.


How can i do this.


Thanks

Edited by: Vedant on Sep 19, 2011 1:15 AM
This post has been answered by hm on Sep 19 2011
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 17 2011
Added on Sep 19 2011
5 comments
1,088 views