Cognos Analytics

Cognos Analytics

Connect, learn, and share with thousands of IBM Cognos Analytics users! 

 View Only
  • 1.  Expression for render variable does not work

    Posted Mon March 22, 2021 10:14 AM
    I have a report with 4 pages formatted as tabs. Each tab has a different name and contains a list table. I would like to list tables to render only when the tab it is on, is chosen. I created a variable to be used as render variable for the list table. I tried both boolean and string variables. If I put in the boolean variable an expression, for example "PageName()='MyFirstTabName', when I go to the first tab the list table does not appear at all. If I put in the variable expression "1", then the list table renders. To check if this is a problem somehow of string format, I tried putting also "character_lenght(PageName())=name_number". I also tried similar but with string variable, as well as I tried to use if else clause in the expressions. Nothing works. Does any of you know what could cause this problem?


    Cognos Analytics 11.0.13


    ------------------------------
    Katarzyna Karpińska
    ------------------------------

    #CognosAnalyticswithWatson


  • 2.  RE: Expression for render variable does not work

    Posted Mon March 22, 2021 12:46 PM

    Hi Katarzyna,

    Maybe something with the PageName() function. Try the functions below. This should work.

    I have a report with a prompt with static choices 1,2,3 for page 1,2 or 3. This is a required prompt (variable pPage) with a default selection of 1.
    Then the render variables on the pages are boolean variables.
    For page1: bPage1 with a definition of ParamValue ( 'pPage' ) = '1'
    For page2: bPage2 with a definition of ParamValue ( 'pPage' ) = '2'
    For page3: bPage3 with a definition of ParamValue ( 'pPage' ) = '3'



    ------------------------------
    Thomas van der Meer
    ------------------------------



  • 3.  RE: Expression for render variable does not work

    Posted Wed March 24, 2021 08:56 AM
    Good Morning,

    I recommend that if you have four that that you have four queries even if the queries contain the same variables.  One query for each tab. If you are worried about overhead, then you may need additional system resources.

    Warm Regards,
    Eli