COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Framework Manager => Topic started by: tibo-k3 on 19 May 2011 03:38:08 AM

Title: Measure dimensions regarding Regular Dimensions
Post by: tibo-k3 on 19 May 2011 03:38:08 AM
Hi,

I'd like to know if there is any way (and how to process) to set the source of a measure dimension regarding which regular dimension is used or not, in the table.

For instance :
- 3 regular dimensions: A, B and C
- 1 measure dimension: M

And for M :
If A is used in the table then M = [DATABASE].[COLUMN_1]
If B is used in the table then M = [DATABASE].[COLUMN_2]
If C is used in the table then M = [DATABASE].[COLUMN_3]
If A and B are used then M = [DATABASE].[COLUMN_4]

etc...

Thanks a lot !

-----------

Cognos 8.4
FrameWork Manager + Analyse Studio + Report Studio
Title: Re: Measure dimensions regarding Regular Dimensions
Post by: blom0344 on 19 May 2011 03:11:55 PM
We basically use a workaround for this type of functional demand. Define your fact data as a collection of unions and add a special filter dimension (in a seperate folder: "Mandatory filter") to select data from 1 of the 4 sets.

The fact union would read something like:

SELECT 'A', [DATABASE].[COLUMN_1]
FROM ....
UNION ALL
SELECT 'B', [DATABASE].[COLUMN_2]
FROM ....
UNION ALL
SELECT 'C', [DATABASE].[COLUMN_3]
FROM ....
UNION ALL
SELECT 'A+B', [DATABASE].[COLUMN_4]
FROM ....