Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
Not applicable

How I get a formual as dimension


Hello together,

does anyone know, how I get formulas as Dimension.

here you see the example:

Colum IColumn IIColumn I / Column 2Column I + Column II
122261124
124262126
126263128

Thanks

1 Solution

Accepted Solutions
Employee
Employee

Re: How I get a formual as dimension

You can create a calculated dimension and wrap your expression in an AGGR function.

aggr(  sum(Column I) / sum( Column II) ,  <Dimension> )

5 Replies

Re: How I get a formual as dimension

Employee
Employee

Re: How I get a formual as dimension

You can create a calculated dimension and wrap your expression in an AGGR function.

aggr(  sum(Column I) / sum( Column II) ,  <Dimension> )

Not applicable

Re: How I get a formual as dimension

What does you mean with <Dimension> is this a standarfield or I have to Change the <Dimension> in an other word?

Employee
Employee

Re: How I get a formual as dimension

Its a generic placeholder for the dimensional values you are aggregating over

In your example it would probably look like something like this:

=aggr( sum([Column I])/sum([Column II]), [Column I],[Column II])

In practice, this isn't a great example because if column1 and column2 are being used as dimensional values , the straight table will only show unique combinations of I and II.  So if you had a duplicate record it would show as 1 record, but the calculation would take into account both as it aggregates both.

I would suggest using non-numeric dimensional values for this technique like Region or Year etc...

Not applicable

Re: How I get a formual as dimension

Use calculated Dimension

Community Browser