COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: thedon_1 on 13 Dec 2011 05:48:20 AM

Title: Crosstab with a measure as a column
Post by: thedon_1 on 13 Dec 2011 05:48:20 AM
Say for example I have a crosstab with country as a column, product as a row and profit as a measure.

Can I add another measure, e.g. costs to the crosstab, but as a column next to Country? I don't need a seperate value per product, just one overall.

It would in theory be like adding a measure like a dimension but I don't know if this can be done.

Thanks
Title: Re: Crosstab with a measure as a column
Post by: tibo on 13 Dec 2011 05:56:19 AM
hello,

you can do this, but you should use country as a 'supercolumn'. Just add country as a column in the crosstab, and drag the two measures (profit and cost) you want to use to the downside of the countryfield, it should look like this
                    country                    country                      country ....               
product     profit        cost          profict       cost              profit       cost....
product
product
...

hope this helped you,
best regards
Title: Re: Crosstab with a measure as a column
Post by: thedon_1 on 13 Dec 2011 06:02:20 AM
Hi

Your above solutution is good but not really what I need, I need the second measure to appear just once as a column.
Title: Re: Crosstab with a measure as a column
Post by: charon on 13 Dec 2011 06:16:30 AM
hi there,...

hm..im still not quite sure what u mean. would u mind giving an example like tibo?
Title: Re: Crosstab with a measure as a column
Post by: thedon_1 on 13 Dec 2011 06:21:50 AM
Sure, here you go.

country     cost                country                      country ....               
product       x                    profict                       profit      ....
product       x                    profict                       profit      ....
product       x                    profict                       profit      ....

Title: Re: Crosstab with a measure as a column
Post by: blom0344 on 13 Dec 2011 06:24:58 AM
Simply drag the new measure to the extreme right of the crosstab till  the  triple  line  (thin-thick-thin) spans the entire crosstab. This positions an additional measure to the right of the grid..
Title: Re: Crosstab with a measure as a column
Post by: thedon_1 on 13 Dec 2011 08:58:42 AM
Thanks mate.

Can I make cost an average but keep profit as a total?

When I try in the bottom left corner, I change cost as an average but it also changes profit.
Title: Re: Crosstab with a measure as a column
Post by: blom0344 on 14 Dec 2011 02:00:12 AM
You need to change the aggregate setting of each individual dataitem, not in the crosstab intersection..
Title: Re: Crosstab with a measure as a column
Post by: thedon_1 on 14 Dec 2011 04:13:34 AM
Perfect, thanks