RTF Template in BI Publisher

Use Case 1 

• Show data in tabular format. 

• Provide a Report Name

• Repeat Table Header in each page. 

• Sort data in descending order using Invoice Number. 

<?sort:INVOICE_NUM;'descending'?> 

• Show or Limit only 10 records per page. 

<?if:position() mod 10 =0?> <xsl:attribute name="break-before">page</xsl:attribute> <?end if?> 

• Show “NO DATA FOUND” if query doesn’t fetch any data <?choose:?> <?when:count(INVOICE_NUM) > 0?> <?end when?> <?otherwise:?> NO DATA FOUND <?end otherwise?> <?end choose?> 

RTF Template in BI Publisher 

Use Case 2 

• Show PO Header Information in Form Layout and PO Lines in Table Layout. 

• Provide a Report Name • Add Header to insert company logo on the left side and Date Timestamp using extended XSL Function on the right <?xdoxslt:sysdate('DD-MON-YYYY HH24:MI')?> 

• Always show a PO from a new Page <?split-by-page-break:?>

 • Decode the PO Status to a user friendly status using extended SQL Function <?xdofx:decode(PO_STATUS,'OPEN','Open PO','CLOSED', 'Closed PO','Others')?> 

• Calculate Line Amount <?ITEM_UNIT_PRICE*ITEM_QUANTITY?> 

• Calculate the PO Amount (sum of all line amount) 

1. <?xdoxslt:set_variable($_XDOCTX, 'TotLineAmt',0)?> 

2. <?xdoxslt:set_variable($_XDOCTX, 'LineAmt',ITEM_UNIT_PRICE*ITEM_QUANTITY)?> 

3. <?xdoxslt:set_variable($_XDOCTX, 'TotLineAmt',xdoxslt:get_variable($_XDOCTX, 'TotLineAmt')+xdoxslt:get_variable($_XDOCTX, 'LineAmt'))?> 

4. 2 & 3 can be combined into one RTF Template in BI Publisher <?xdoxslt:set_variable($_XDOCTX, 'TotLineAmt',xdoxslt:get_variable($_XDOCTX, 'TotLineAmt')+ITEM_UNIT_PRICE*ITEM_QUANTITY)?> 

5. <?xdoxslt:get_variable($_XDOCTX, 'TotLineAmt')?> 

• Show Total Line Amount or PO Amount in words <?xdoxslt:toCheckNumber($_XDOLOCALE, xdoxslt:get_variable($_XDOCTX, 'TotLineAmt'), 'USD')?>

 RTF Template in BI Publisher

https://www.youtube.com/watch?v=GCkyK8iWbT0

Comments

Popular posts from this blog

Install and Configure OBIEE 12c on Linux VM

Web Based Electricity Billing and Payment System with SMS Notification

How to create oracle APEX plugins