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

A 'conditional slicer' question

Started by cogswell, 26 Jul 2011 06:53:24 AM

Previous topic - Next topic

cogswell

So, I have a value prompt with use values of 0, 1 and 2. I need to apply a particular slicer expression if that value prompt has 0 or 1, and not apply it when it is 2. I tried the following as a slicer expression:

((?Prompt? = 0 OR ?Prompt? = 1) AND <SlicerMemberSetExpression>) OR (1=1)

I get the following error:

QuoteOPR-ER-0025 The following OLAPPlanner internal error occurred: 'OPASSERT(OQP_DYNAMIC_CAST(OPExpressionConditionPtr,pOPItem2->GetExpr())) in OPQueryItemGenerator::SearchInitialItemExpression at OLAPPlannerOLAPTransformations.cpp:256'.

Thanks to all who reply.

cogswell

HELP! PaulM?

I even tried the following but got the same error.

((?Prompt? = 0 OR ?Prompt? = 1) AND <SlicerMemberSetExpression>) OR (<SlicerMemberSetExpression2>)

CognosPaul

Why not change the 0, 1, 2 to the MUNs of the members you want to slice by?

cogswell

Quote from: PaulM on 27 Jul 2011 01:34:05 PM
Why not change the 0, 1, 2 to the MUNs of the members you want to slice by?

Because they're dynamic sets, not single categories. :)

CognosPaul

a slicer can only be a member or a set, and there can't be an or clause.

so that being a said, a few questions:

This is a true OLAP cube, right?

if the values are always going to be 1 or 2 or 3 you might be able to do somehing like:
#substitute('1','[cube].[dim].[hier].[level]->[pc].[abc]',substitute('2','[cube].[dim].[hier].[level]->[pc].[abc]',substitute('3','[cube].[dim].[hier].[level]->[pc].[abc]',prompt())))#