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

Case statement

Started by HERRERA, 22 Jan 2008 11:48:06 AM

Previous topic - Next topic

HERRERA

Hi, i have a calcutated field with "total for" , using a case statement, but my expression does not function.

The expression :

Case
When [metric_id1] = 999
Then Total ([value] for [bsc_name])
Else [value]
End


The result is ignoring the filter.

Its possible use "total for" with "case" ???


Tks
Herrera

Suraj

Can't say why it's not working, everything looks okay.
Try reversing the condition.
Case
When [metric_id1] <> 999
Then [value]
Else Total ([value] for [bsc_name])
End

HERRERA

Quote from: Suraj Neupane on 22 Jan 2008 12:11:56 PM
Can't say why it's not working, everything looks okay.
Try reversing the condition.
Case
When [metric_id1] <> 999
Then [value]
Else Total ([value] for [bsc_name])
End


Did not function........ :(





Suraj

then create a data item that only calculates total for 999:
Data item1:
Case
When [metric_id1] = 999
Then Total ([value] for [bsc_name])
Else  null
End
This should work fine. It not, then you have other issues.
After this is working create another data item to use in report.
Data item2:
case When [metric_id1] = 999
Then [Data item1]
Else  [value]
End
Try different approaches and start from a simple calculation, check the data and then proceed by adding complexity.

HERRERA

Ok, tks for help !!!!!