Skip to Main Content

DevOps, CI/CD and Automation

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!

How to print "there is not data found for this report" in a XML report

959753Sep 4 2012 — edited Sep 10 2012
Hi ,

User has a requirement that print "there is not data found for this report" when no data found for the report. But I have an issue when I try to achieve this in RTF template. My loop is as below:

<?for-each@section:G_SETUP?>
<?for-each-group@section:G_STATEMENT[STATEMENT_TYPE!='SUMMARY'];./STATEMENT_DATE?><?for-each-group@section:current-group();././SEND_TO_ADDRESS_ID?>
..............
<?end for-each?>
<?end for-each?>

To meet user's requirement, I add an if logic outside the loop. like below:
<?if:count(G_SETUP)<=0?>
there is not data found for this report
<?end if?>
but it does not work.
I have test, even i put some text like '123' outside the loop without if logic, i can not get it printed.

could you please help me?

Best regards
Terrence

Below is the data source file for test:
<?xml version="1.0" encoding="UTF-8"?>

<ARXSGPO>

<LIST_G_SETUP>
<G_SETUP>
<COMPANY_NAME>test for no data found</COMPANY_NAME>
<COA_ID>50348</COA_ID>
<FUNCTIONAL_CURRENCY>EUR</FUNCTIONAL_CURRENCY>
<FUNCTIONAL_CURRENCY_PRECISION>2</FUNCTIONAL_CURRENCY_PRECISION>
<REPORT_NAME>AR Customer Balance Statement Letter</REPORT_NAME>
<PARENT_REQUEST_ID>2809593</PARENT_REQUEST_ID>
</G_SETUP>
</LIST_G_SETUP>
</ARXSGPO>

Edited by: 956750 on Sep 4, 2012 12:22 AM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 8 2012
Added on Sep 4 2012
14 comments
2,926 views