# New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Make your voice heard! Participate in the 2020 Wisdom of Crowds® Survey. BEGIN SURVEY
Highlighted
Partner

## Expression as a dimension

I have a table

ASum(C)
a110
a215
a320
a425
a530
a635

I need a dimension, something similar to class function

if(Sum(Aggr(Sum(C),A))>=10 and Sum(Aggr(Sum(C),A))<20,'Low',

if(Sum(Aggr(Sum(C),A))>=20 and Sum(Aggr(Sum(C),A))<30,'Medium','High'))

So, I want Low, Medium, High as Dimension values and then want some expressions to be aggregated based on the calculated dimension.

Thanks

Naresh

Tags (3)
1 Solution

Accepted Solutions
MVP

## Re: Expression as a dimension

Try this

Aggr(

If(Sum(C) >= 10 and Sum(C) < 20, 'Low',

If(Sum(C) >= 20 and Sum(C) < 30, 'Medium', 'High'))

, A)

4 Replies
MVP

## Re: Expression as a dimension

Try this

Aggr(

If(Sum(C) >= 10 and Sum(C) < 20, 'Low',

If(Sum(C) >= 20 and Sum(C) < 30, 'Medium', 'High'))

, A)

Highlighted

## Re: Expression as a dimension

Will you able to create calc. dim like below?

=if([Sum(C)]>=10 and [Sum(C)]<20,'Low',if([Sum(C)]>=20 and [Sum(C)]<30,'Medium','High'))

Or

=if(Aggr(Sum([Sum(C)]),A)>=10 and Aggr(Sum([Sum(C)]),A)<20,'Low',if(Aggr(Sum([Sum(C)]),A)>=20 and Aggr(Sum([Sum(C)]),A)<30,'Medium','High'))

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Highlighted
Partner

Thanks Sunny

Highlighted
Partner

## Re: Expression as a dimension

Thanks Anil. I tried this.