pape
pape

Reputation: 249

Qlikview - bar chart with multiple dimensions

I have straight table with lot of data...

enter image description here

I need to create bar chart from this table - dimension to be year and expressions Column(1)-Column(2).

  column(1) = sum(Saldo)
  column(2) = sum(Saldo)/3

I try to set dimension to be year and expresion

sum(sum(Saldo) - (sum(Saldo)/3))

but I don't get same total like I get sum of rows of Column(1)-Column(2).

This is because I need to include in dimension Line.

How can I create bar chart with dimensions I have in straight table...?

Any idea?

Upvotes: 0

Views: 743

Answers (1)

EldadT
EldadT

Reputation: 932

You need to use AGGR function:

sum(aggr(sum(Saldo) - (sum(Saldo)/3),Document,Line,Item,Unit))

or just use plain math:

Sum(Saldo * (2/3)) or Sum(Saldo)*(2/3)

Upvotes: 1

Related Questions