COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: tupac_rd on 27 Jun 2008 11:28:33 AM

Title: crosstab report issue
Post by: tupac_rd on 27 Jun 2008 11:28:33 AM
Hi gurus,

I have a crosstab report whose "Crosstab rows" is populated by a query item which is a list of values starting from Jan 2001, Feb 2001, Mar 2001 and so on all the way to Nov2010, Dec 2010.
Now I have to filter the crosstab query based on 2 prompts.

1st prompt (single select) would be year month combo from the same query item above. Lets say the value is ?p1? = Dec 2007.

2nd prompt(multiselect) is  year.  for eg., ?p2?=2006.

For the above 2 prompt selections, the query should display values from Jan 2006 to Dec 2007. I know how to do this if year selected is only 2006, but the way prompt filter is set up the prompt is becoming single select. I need to change the filter expression so that the 2nd prompt is multiselect. So if the users select multiple years say 2005 and 2006, then the query should bring back Jan 2005 to Dec 2007.

please let me know how to do this.

Thanks
dd
Title: Re: crosstab report issue
Post by: blom0344 on 28 Jun 2008 01:37:59 PM
multiselect prompts require a different syntax in the filter expression:



[somenamespace].[someyearitem]
in ?select_year?

Title: Re: crosstab report issue
Post by: MDXpressor on 09 Jul 2008 10:29:45 AM
Your filter probably ready with the operator as an equal ([year]=?year prompt?) as stated above, you need to change that operator to the 'in' operator ([year] in (?year prompt?)).  The other thing of importance is to change your prompt page (if you actually created one).  If the prompts are not being dynamically generated, they are likely still on Multi Select = No.