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

adding 2 tuples

Started by axxo, 26 Mar 2009 07:13:38 PM

Previous topic - Next topic

axxo

How can I add 2 tuples together?

Crosstab is divided into 3 nested nodes at top and 3 nested nodes at the bottom.

There are 2 rows right at the very bottom in the crosstab not within any of those nodes.
data item 1 has expression tuple([Total(CC11)]) (displays correct data)
data item 2 has expression tuple([CC75]) (displays correct data)

I want to add
data item 3 which adds data item 1 and data item 2 together

I have used expression
tuple([CC75])+tuple([Total(CC11)])

This results in error in each fact cell for data item 3






axxo

#1
It's now partly working. I have used member sets - I added [data item 1] (a total of cost centre 11) and [data item 2] (running total of cost centre 75) to a member set. Problem is [dataitem2] is a running total so when I try to add the 2 rows using total( [measure] within set set ([row_edge])) Cognos doesnt perform the running total on [dataitem2] first.

Any even vague ideas?

axxo

#2
Adding 2 tuples in my crosstab wasnt too hard. Just created 2 tuples in my crosstab. Then 2 more data items that used the value() function to bring in each tuples value. Then add those 2 data items together [A] + ['B].

However, I belive it is impossible to do this if the data item you are trying to add uses a running-total() function. Simply impossible. Don't try it people I have wasted a LOT of time trying to do this just negotiate with your BA to have the report modified :)

Essentially what I am wanting to do is get a YTD (running total) of cost centre 11 from one level of a crosstab then subtract that from a MTD total of cost centre 75 that exists in another level of the crosstab. I can not do this when using running-total() I can however achieve success by removing the running-Total() effectively subtracting MTD of CC11 instead of YTD of CC11. Cognos does not know it has performed an error before the crosstab is produced, instead it outputs #!error in the fact cells.