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

issue to sort data item based on prompt parameter

Started by philelmousse, 13 Dec 2011 03:26:06 AM

Previous topic - Next topic

philelmousse

Hello, I have a data item built like this :

#prompt('p_Time','token','[REPORTING LAYER].[Time].[Time]')#

My dimension Time has "Year","Month" and "Day" level. I would like to sort that data item with the business key of. I'm not able to do it... can you help please ?

CognosPaul

Create and sort using a new data item:

roleValue('_businessKey',[Data Item])

With [Data Item] containing the prompt macro.

philelmousse

My business key are char format so I created a MemberDescription with integer values. I used something like to sort the dataitem

roleValue('_memberDescription',[Data Item])

It doesnt work. When I try to display that data item it returns the member caption of the month. Do you have an idea ?

CognosPaul

Right click on the member from the tree and click properties. the roleValue returns any of those strings. So if memberDescription doesn't appear there, you'd have to find a different solution.

Your prompt is returning the level? Does every level have Member Description? You might be able to get away with something like

order(#prompt('p_Time','token','[REPORTING LAYER].[Time].[Time]')# , #prompt('p_Time','token','[REPORTING LAYER].[Time].[Time]') + '.[Member Description]'#, asc)

philelmousse

Thanks for your reply. I just faced the issue by sorting the dimension directly in framework manager by the member_description.