COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Report Studio => Topic started by: fkli222 on 18 Dec 2013 08:37:01 AM

Title: Value Prompt Filter Selection
Post by: fkli222 on 18 Dec 2013 08:37:01 AM
Hi everyone,

I created a value prompt for the months dimension from my planning cube. The dimension shows every month for hours and dollars. How do I only show the months with hours?

So basically, in the value prompt list it shows more than I want to show. How do I filter out or select only those that I want to see.

Thank you!
Title: Re: Value Prompt Filter Selection
Post by: MFGF on 18 Dec 2013 11:21:43 AM
If you defined a value prompt in your report, it will be populated using items in a query. You can add a calculated expression to this query which uses a filter() function to filter the members to a list you desire, then use this calculated item in your prompt as the Use value.

Cheers!

MF.
Title: Re: Value Prompt Filter Selection
Post by: fkli222 on 19 Dec 2013 01:07:13 PM
Thanks MGMF for the advice.

I am still trying to get the hang of report studio functions. Where do I put the Query Calculation Expression so it can be seen in "Use Value."

I created one and tried to run the report as well to see what it would do but I got this error

"QE-DEF-0260      Parsing error before or near position: 68 of: "filter ( [MMC Fee Tracker].[MonthYear Calc].[MonthYear Calc Name] ="

Thanks again!


Title: Re: Value Prompt Filter Selection
Post by: MFGF on 19 Dec 2013 02:37:21 PM
Go to the query explorer and into the query populating the prompt. Drag in a new calculated item from the toolbox.

The syntax of a filter function is filter([level or hierarchy], {expression which evaluates to true or false})

In your example you have included an expression but not the level or hierarchy you want the expression to apply to.

MF.