COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Framework Manager => Topic started by: ordotan on 01 Aug 2013 05:57:25 AM

Title: Referencing Parameter Map with parameter from the prompt
Post by: ordotan on 01 Aug 2013 05:57:25 AM
Hi,

Is there a way to access a pre-defined parameter map with some parameter?

Let's say I have the  following parameter map, which called "SampleMap"




1 A
2 B
3 C

And I want to create a filter based on this parameter map, and I want to referenct it with parameter ('param') from my prompt page.

I want to do something like -

#$SampleMap{#sq(prompt('param','string'))#}# = {some condition}

But it doesn't pass validation, due to wrong syntax.

Any suggestions ?



Title: Re: Referencing Parameter Map with parameter from the prompt
Post by: CognosPaul on 01 Aug 2013 07:28:26 AM
You only need hashes (#) at the beginning and end of a macro expression. Get rid of the ones around the prompt.

Second, a string parameter in the prompt will always return a a value inside two single quotes. You don't need the SQ there.
Title: Re: Referencing Parameter Map with parameter from the prompt
Post by: ordotan on 01 Aug 2013 09:57:37 AM
Thanks