Follow us: Connect on YouTube Connect on YouTube Connect on YouTube

Pages

Saturday, 11 November 2017

Display Parameter Values in RTF Template

0 comments



We can build XML report by using RDF (By using report builder) and Data templates

Here we are going learn in both ways how show Parameter values 


Showing parameter values in RTF template by RDF report 


Take formula column at report level write the following coding in PLSQL block

Begin
Return (:Parameter);
End;

Refer the XML tag into the RTF 


Showing parameter values in RTF template by data template 

Here we can show in 2 steps:


Step1:
 
Create new SQL in Data template

<sqlStatement name="Q_PARAM_DET">
<![CDATA[
  SELECT  TO_CHAR (TO_DATE (:P_FROM_PO_DATE, 'YYYY/MM/DD HH24:MI:SS'),'DD-MON-YYYY') from_date
        , TO_CHAR (TO_DATE (:P_TO_PO_DATE, 'YYYY/MM/DD HH24:MI:SS'), 'DD-MON-YYYY')  to_date
        , fnd_global.conc_request_id request_id
        ,(SELECT user_name
            FROM fnd_user
           WHERE user_id = fnd_global.user_id) run_by
        , to_char(sysdate,'DD-MON-YYYY HH:MI:SS AM') sys_date
   FROM DUAL
]]>
</sqlStatement>

Step2:

Create data source shown below


<group name="G_PARAM_DET" source="Q_PARAM_DET">    
     <element name="from_date"   datatype="VARCHAR2"     value="from_date"/>
     <element name="to_date"     datatype="VARCHAR2"     value="to_date"/>
     <element name="request_id"  datatype="NUMBER"       value="request_id"/>
     <element name="run_by"      datatype="VARCHAR2"     value="run_by"/>
     <element name="sys_date"    datatype="VARCHAR2"     value="sys_date"/>       
   </group>



Continue reading >>

Wednesday, 8 November 2017

No Data Found in XML/BI Publisher

0 comments



You can place No Data Found if report did not return any records as shown below and check record count from main group with if condition

                      ***** No Data Found *****

<? if:count (G_EMPNO)=0?>***** No Data Found *****<?end if?>


You can show message like End Of Report as shown below and check record count from main group with if condition


***** End Of Report *****

   <? if:count (G_EMPNO)>0?>***** End Of Report *****<?end if?>


Sample RTF Template:


No Data Found in XML/BI Publisher

End of Report output:

End of Report output
 
Continue reading >>