If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

[Solved] Multiple prompts with conditional variables

Started by ole115, 28 Oct 2005 11:42:02 AM

Previous topic - Next topic

ole115

Hi,

I have a report with 3 columns and I have 3 prompts for it. Based on what prompt has been chosen, I display either column 1, 2 or 3 (using conditional variables). I could make it work whenever you pick just one. But I was not able to figure out how to make it work if you choose multiple prompts (which is a part of requirements). Right now if you choose all, for example, the output displays none. So, the question is: can we use multiple conditions at the same time or can we apply multiple conditional variables to the same column?

Thanks.

mallika

is it necessary to have three seperate prompts for each of the three fields? or could u use a single prompt with 3 static variables, one for each column (just an idea). If you have to have three prompts, then try creating string variable with n no. of values for a combination of three inputs (7 combinations). In your expression use case statements with DisplayParameterValue using all three parameters eg. when 1 & 2 then A, when 2 & 3 then B etc. Then associate each of these seven values to the corresponding columns.


This should work.. sorry coundn't try it out first.. and there might be an easier way too.

ole115

Sorry, I didn't explain it correctly. I have a single prompt with 3 static variables: column 1, column 2, column 3. They are check boxes. So, you can select one or multiple. Then I have 3 variables: for column 1 I have ParmDisplayValue='Column1' and so on. For every column I specified corresponding conditional variable. So, for column 1 I specified variable column1. If I just pick one, the right column disappears. But if I pick multiple, nothing shows up. I could not find a way to assign multiple conditional variables to a single column in case I wanted to do a combination of 2 or 3. I was expecting the ReportNet to pick up all the conditions, and do something like ParmDisplayValue='Column1'  and ParmDisplayValue='Column2' , but it seems like it does not work that way.

mallika

i don't think you can assign multiple variables to the same cell/column at least definitly not in the properties pane, and that is why my earlier suggestion was to create a single string variable with multiple values (you would need 7 values if you have 3 columns).Your expression should include the multiple conditions. Then u can associate each value to the corresponding columns.

ole115

Thanks, Mallika. It worked with string variable. Case closed.