Reporting and Analytics for ERP

Get Involved. Join the Conversation.

Topic

    Lakmal Somasiri
    How to save a report output with date suffix?
    Topic posted September 2, 2019 by Lakmal SomasiriBlue Ribbon: 750+ Points, tagged BI Publisher, Reports, Tip 
    36 Views, 4 Comments
    Title:
    How to save a report output with date suffix?
    Summary:
    How to save a BIP report output with date suffix.
    Content:

    I managed to get a complete XML output using select query with XMLELEMENT () tag using Data Model. Now I want to save the output to following file format. "Output_20190902.xml". How to do this?

    Note: If I created a BIP template and get the output as a Data(XML) I can get DM_Output.xml file with following format. But I dont want outer tags. I want the data inside <CUST_XML> tag to save in new xml file with date suffix.

    <!--
    Generated by Oracle BI Publisher -Dataengine, datamodel:_Custom_DM_xdm
    -->
    <DATA_DS>
    <G_1>
    <CUST_XML>
    <?xml version="1.0" encoding="utf-8"?> <Document my xml data comes here.....</Document>
    </CUST__XML>
    </G_1>
    </DATA_DS>
    Version:
    18B

    Comment

     

    • Sudhir Kolli

      We need to get more details on the type of Data Model used and the requirement.
      Please provide us with an archive of data model, sample XML and template for our review.

      • Lakmal Somasiri

        Hi Sudir,

        Please find sample DM, report archive and output for your info.

         In the output file(Sample_Report_Output.xml) following output is there. I want to omit outer tags and take a content between <CUST_XML> and </CUST_XML> into my output file and dynamically change output file name from Sample_Report_Output.xml to Sample_Report_Output20190902.xml

        <DATA_DS>
        <G_1>
        <CUST_XML>
        <?xml version="1.0" encoding="utf-8"?> <Document> <Header> <Line>2019-09-02</Line> </Header> </Document>
        </CUST_XML>
        </G_1>
        </DATA_DS>
         

        Regards,

        Lakmal

    • Tom Strudley
      To customise your XML use XSLT stylesheets https://docs.oracle.com/middleware/12211/bip/BIPRD/GUID-B21A0786-427A-4853-8225-F5C6B7CCF39E.htm#BIPRD2843 For file names you can use bursting https://docs.oracle.com/cd/E28280_01/bi.1111/e22258/add_burst_def.htm#BIPDM344 especially if this is going to an end point, if not during a schedule you can look to do this https://community.oracle.com/message/13878967#13878967