NVL In RTF Template — Oracle Analytics

Oracle Analytics Publisher

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

NVL In RTF Template

Closed
3945
Views
9
Comments
Thilib Arivu
Thilib Arivu Rank 4 - Community Specialist
edited Oct 25, 2024 7:34PM in Oracle Analytics Publisher

Summary

NVL In RTF Template

Content

Hi Team,

How to use NVL In rtf templete

If

<ABC> is null the it should write <DEF>

Thanks

AT

Answers

  • Thilib Arivu
    Thilib Arivu Rank 4 - Community Specialist

    Can we use like this ?

    <?xdofx: if ABC !='' then 'ABC' else 'DEF'?>  <?end if?>

    Thanks

    AT

  • Rajesh123
    Rajesh123 Rank 6 - Analytics Lead

    yes you can write like that

  • Rajesh123
    Rajesh123 Rank 6 - Analytics Lead

    Put in one column tag

    <?if:string-length(ABC) != '0 '?>

    <?ABC?>

    <?end if?>

    <?if:string-length(ABC) = '0 '?>

    <?DEF?>

    <?end if?>

    OR

    <?choose:?>

      <?when:ABC!=''?> ABC <?end when?>

      <?otherwise:?>DEF<?end otherwise?>

    <?end choose?>

  • Thilib Arivu
    Thilib Arivu Rank 4 - Community Specialist

    Hi Rajesh,

    One small doubt

    Do we need to pass it in a String or with String

    <?xdofx: if ABC !='' then 'ABC' else 'DEF'?>  <?end if?>

    or

    <?xdofx: if ABC !='' then ABC else DEF?>  <?end if?>

    Since ABC is Expression coming from the DB

  • Venkat Thota - BIP
    Venkat Thota - BIP Rank 7 - Analytics Coach

    You can directly use nvl function using xdofx function in RTF template

    <?xdofx: nvl(ABC,'DEF')?>  where ABC will the column or field. Thanks

  • Vani-R
    Vani-R Rank 4 - Community Specialist

    Use the expression which Rajesh123 gave (<?ABC?> should be defined as BI Publisher Field)

    Put in one column tag

    <?if:string-length(ABC) != '0 '?>

    <?ABC?>

    <?end if?>

    <?if:string-length(ABC) = '0 '?>

    <?DEF?>

    <?end if?>

  • Bruce Wang
    Bruce Wang Rank 3 - Community Apprentice

    <?xdoxslt:ifelse(ABC !='',ABC,DEF)?>

  • Ankur.Bansal
    Ankur.Bansal Rank 2 - Community Beginner

    I have tried all the suggested options but nothing seems to work, I am pretty sure direct NVL used to work before

  • Mallikarjuna Kuppauru-Oracle
    Mallikarjuna Kuppauru-Oracle Rank 8 - Analytics Strategist

    Hi @Ankur.Bansal

    This is very old Thread if you still looking for an help/answer from community can you start new thread ?

    https://community.oracle.com/products/oracleanalytics/categories/bi-publisher

    Regards,

    Arjun

This discussion has been closed.