COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: SGD on 16 Nov 2011 11:52:54 PM

Title: Resolved: Hide/Render page based on multi-select value prompt
Post by: SGD on 16 Nov 2011 11:52:54 PM
Hi All,

I have 7 pages in my report which are actually 7 different systems. All these 7 systems are availble in multi select value prompt. User requirement is that he can select either one or multiple or all systems in multi select value prompt and based on selection report page(s) should get displayed.

I know I need to apply conditional formatting to acheive this task but there are total 7 diffrenet systems which requires lot of different combinations to be added.

Could please anyone suggest about easy and optimum way to implement the same? Also, do I need to use 'string' or 'boolean' variable?

Thanks in advance.

Your help is highly appreciated.
Title: Re: Hide/Render page based on multi-select value prompt
Post by: pricter on 17 Nov 2011 02:14:03 AM
Check this topic promptpageprompt with multiple values (http://www.cognoise.com/community/index.php?topic=17874.0)
Title: Re: Hide/Render page based on multi-select value prompt
Post by: SGD on 17 Nov 2011 03:37:43 AM
Hi pricter,

Thanks for your reply however I have already tried that solution but its not working as expected  :(
Title: Re: Hide/Render page based on multi-select value prompt
Post by: pricter on 17 Nov 2011 03:58:05 AM
At which point does not work as as expected?
Title: Re: Hide/Render page based on multi-select value prompt
Post by: SGD on 18 Nov 2011 05:29:35 AM
Hi pricter,

As I mentioned in my original post, there are 7 different Systems. Thses 7 systems are displayed in multi-select value prompt. User can select either 1 or multiple or all systems and run the report.

Respective single page gets displayed properly when User selects single system in multi-select value prompt but it does not show respective multiple pages when User selects multiple systems in multi-value prompt.

Below are my system names which are populating directly from database table:

AoA
HBD
HWD
CWD
DED
WILD
BAM
WADE

Please suggest.
Title: Re: Hide/Render page based on multi-select value prompt
Post by: pricter on 18 Nov 2011 07:24:53 AM
Which is the expression that you use in variable?

If you add a layout expression to a page (Paramvalue('yourprameter) and select multiple values on the report what does appear?
Title: Re: Hide/Render page based on multi-select value prompt
Post by: SGD on 20 Nov 2011 10:28:16 PM

Single selected value: AoA

Multi selected value: AoA, HBD, WILD, BAM

All selected value: AoA, HBD, HWD, CWD, DED, WILD, BAM, WADE

I am using expression as below for string conditional variable:

QuoteParamValue('p_system')
Title: Re: Hide/Render page based on multi-select value prompt
Post by: pricter on 21 Nov 2011 02:47:33 AM
Instead of using a string variable create seven boolean variable one for each system

For example  use the following expression
for AoA
ParamDisplayValue('p_system') contains 'AoA'
for HBD
ParamDisplayValue('p_system') contains 'HBD'

and so on
Title: Re: Hide/Render page based on multi-select value prompt
Post by: SGD on 21 Nov 2011 03:24:59 AM

Thanks pricter... :)

your solutions worked...!!!