xmlrtfbi-publisherxml-publisheroracle-xml-publisher

BI Publisher - ignore section - based on info from XML input data


I have the following scenario:

I'm developing a rtf report in BIP desktop 11 containing 3 sections: intro, content, ending. Based on xml input data, each section may generate one or multiple pages. Because each section has it's own unique header and footer, I divided the rtf into 3 sections (with MS Word tool Page Layout -> Breaks -> Section Breaks - Next Page).

.. all of this let's say for an Active client. (first tag from XML is Active/Inactive)

If the client is Inactive the report should generate an empty one-page pdf. Here's the problem: For inactive clients, report generates 3 blank pages (because document is split into 3 sections). Any thougths on how to fix that? Maybe a different approach in dividing the sections?

Thanks in advance.


Solution

  • Solved the issue by using the following code:

    Intro

    <?for-each@section:Client[Status='Active']?>
    

    ...

    Content

    ...

    Ending

    ...

    <?end for-each?>