Try encapsulating your original query into the form of a subquery:

*SELECT nvl(original_qry.cnt,0) as total_count,*
*   original_qry.est_name,*
*   original_qry.category_description*
*FROM (*

SELECT   COUNT(*) as cnt, est_name, category_description
    FROM bl_tb_external_issues ei,
         bl_tb_external_issues_dtl et,
         bl_tb_blood_units bu,
         bl_tb_products bp,
         bl_tb_blood_categories bc,
         mst_tb_establishment_mast em
   WHERE
   ei.INSTID=em.EST_CODE and
    ei.issueid = et.issueid
     AND et.unitid = bu.unitid
     AND bu.product_id = bp.product_id
     AND bp.blood_category_id = bc.blood_category_id
     AND ei.status = 'A'
GROUP BY est_name, category_description;
*) original_qry*


I referenced your original query with the alias "original_qry" and added an
alias to your count(*) column as "cnt"; I simply selected from the results
of the original query using the previous suggestion to apply the NVL
command. In this context, it should work.


Rich Pascual


On Fri, Jan 21, 2011 at 8:32 PM, faizal mangattil`
<[email protected]>wrote:

> IN THIS BLANK COLUMN NO CELL VALUE. THTS WHY I CAN'T APPLY FORMAT TRIGGER
> AND NVL ALSO
>
>
> On Wed, Jan 19, 2011 at 5:40 PM, jomesh joseph <[email protected]>wrote:
>
>> use triggers
>>
>>
>>
>> On Wed, Jan 19, 2011 at 9:53 AM, faizal mangattil` <
>> [email protected]> wrote:
>>
>>> created one report   with this query
>>>
>>>
>>> SELECT   COUNT (*), est_name, category_description
>>>     FROM bl_tb_external_issues ei,
>>>          bl_tb_external_issues_dtl et,
>>>          bl_tb_blood_units bu,
>>>          bl_tb_products bp,
>>>          bl_tb_blood_categories bc,
>>>          mst_tb_establishment_mast em
>>>    WHERE
>>>    ei.INSTID=em.EST_CODE and
>>>     ei.issueid = et.issueid
>>>      AND et.unitid = bu.unitid
>>>      AND bu.product_id = bp.product_id
>>>      AND bp.blood_category_id = bc.blood_category_id
>>>      AND ei.status = 'A'
>>> GROUP BY est_name, category_description;
>>>
>>> I want to fill zero in blank cell. see the attached file.
>>>
>>> if anybody can help. it will be appreciable.
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Oracle PL/SQL" group.
>>> To post to this group, send email to [email protected]
>>> To unsubscribe from this group, send email to
>>> [email protected]
>>> For more options, visit this group at
>>> http://groups.google.com/group/Oracle-PLSQL?hl=en
>>>
>>
>>
>>
>> --
>> jomesh joseph veliyath
>>
>>  --
>> You received this message because you are subscribed to the Google
>> Groups "Oracle PL/SQL" group.
>> To post to this group, send email to [email protected]
>> To unsubscribe from this group, send email to
>> [email protected]
>> For more options, visit this group at
>> http://groups.google.com/group/Oracle-PLSQL?hl=en
>>
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Oracle PL/SQL" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/Oracle-PLSQL?hl=en
>

-- 
You received this message because you are subscribed to the Google
Groups "Oracle PL/SQL" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/Oracle-PLSQL?hl=en

Reply via email to