Oracle Analytics Publisher

Welcome to the Oracle Analytics Community: Please complete your User Profile and upload your Profile Picture

How to apply below condition in rtf template for bip report in peoplesoft

Received Response
182
Views
3
Comments
Riya_Maithani-Oracle
Riya_Maithani-Oracle Rank 1 - Community Starter
edited November 2023 in Oracle Analytics Publisher

I have a requirement to achieve the following condition - I need to put up a condition that -

if last character of DESCR field does not have '3'

<print this content>

end-if

I tried with adding the below condition -

However, this gives me nothing? A blank page opens (PS. made sure DESCR(19,1) has the required value I need)

Any suggestions are welcomed.

Answers

  • Federico Venturin
    Federico Venturin Rank 7 - Analytics Coach

    Hi @Riya_Maithani-Oracle ,

    You should update your conditional formatting as follows:

    <?xdofx: if SUBSTR(DESCR,19,1) != '3' then 'print this content' end if?>

  • Riya_Maithani-Oracle
    Riya_Maithani-Oracle Rank 1 - Community Starter

    Thank you for the suggestion. However, in my requirement I need to use 2 different conditional regions to specify the IF and END-IF because the 'print this content' section has a lot of conditions and statements.

    For Example, there is a for-loop and if-else statement and printing multiple field values. All of this is the content that I want to execute and print inside my main substr if condition. Hope this clarifies the requirement.

  • Federico Venturin
    Federico Venturin Rank 7 - Analytics Coach

    Hi @Riya_Maithani-Oracle ,

    In this case, I would update the source query to include the calculation as a new column (e.g. SUBDESCR) directly in the data model, so you no longer need to calculate it in the template.

    Then in your template you can do something like that:

    <?if: SUBDESCR != '3'?> do things <?end if?>