COGNOiSe.com - The IBM Cognos Community

IBM Cognos Analytics Platform => Cognos Analytics => Reporting => Topic started by: PeterDD on 05 Aug 2019 03:04:37 AM

Title: How to show filtered expression from a querycalculation
Post by: PeterDD on 05 Aug 2019 03:04:37 AM
Hi,

in a query there is a field with ledger items (1 to 9000) and amounts
in the page designer a need to show some amount for specific ledger items

I've created a expression:
Case when [ledger item] = '8995'
then [ledger_amount]
else 0
end


but in the page design I only want to show the value <>0
is it possible to make an query calculation that looks like this:

total([ledger_amount] where [ledger item= '8995']) ????

or is there another solution?

thanks
Title: Re: How to show filtered expression from a querycalculation
Post by: BigChris on 05 Aug 2019 04:18:05 AM
I don't know if I'm missing something, but don't you just need a filter that's something like [Ledger Item] = '8995' and [Ledger_Amount] <> 0
Title: Re: How to show filtered expression from a querycalculation
Post by: PeterDD on 05 Aug 2019 04:38:14 AM
Well I need to show more than 1 row for multiples ledger items,
so when I Add a filter it will show only 8995

so in my page layout the first row is to show 8995

then 8603
       8612
8602

6000+ 6001
etc.