# New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
QlikWorld 2022, LIVE in Denver CO., May 16-19, 2022. REGISTER NOW TO RECEIVE EARLY BIRD PRICING
cancel
Showing results for
Did you mean:
Not applicable

## Dimension Help

Hi Friends,

I want to create a dimension in coding or pie chart in design using below measures. Is there any way to do that. please help. Thanks

PAR 7 =sum(If(ArrearsRentals>0,(CapitalArrears/ArrearsRentals),0))

PAR 14 =Sum(If(ArrearsRentals>1,(CapitalArrears/ArrearsRentals),0))

PAR 30 =Sum(If(ArrearsRentals=3,(CapitalArrears/ArrearsRentals),If(ArrearsRentals>3,(CapitalArrears/ArrearsRentals)*2,0)))

PAR 60 =Sum(If(ArrearsRentals=5,(CapitalArrears/ArrearsRentals), If(ArrearsRentals=6,(CapitalArrears/ArrearsRentals)*2,                If(ArrearsRentals=7,(CapitalArrears/ArrearsRentals)*3, If(ArrearsRentals>7,(CapitalArrears/ArrearsRentals)*4,0)))))

1 Solution

Accepted Solutions
Master III

Hi,

You can use ValueList() Function like this

Dimension : =ValueList('PAR7','PAR14','PAR30')

Expression :

Pick(Match(ValueList('PAR7','PAR14','PAR30'),'PAR7','PAR14','PAR30'),sum(If(ArrearsRentals>0,(CapitalArrears/ArrearsRentals),0)),Sum(If(ArrearsRentals>1,(CapitalArrears/ArrearsRentals),0)),
Sum(If(ArrearsRentals=3,(CapitalArrears/ArrearsRentals),If(ArrearsRentals>3,(CapitalArrears/ArrearsRentals)*2,0))))

Regards,

Antonio

9 Replies
Partner

Hi,

You can make calculated dimension, in the expression editor you can us lot of function AGGR, IF ... for making custom dimension.

Partner

yes each PAR become one calculated dimension on chart object.

Not applicable
Author

Thanks daniel and Andrea, But I want to add all PARs into one dimention. Can I do that?

Partner

Could you show some mock up, which describes the result?

Not applicable
Author

As an example, In a pie chart, I want to show the contribution of PARs(Percentages). so there are PAR 7, PAR 14, PAR 30 and PAR 60. I want to show them in an one pie chart. I have attached an excel data sheet for relevant data. Thanks !

Not applicable
Author

Hi, can anyone help me with this?

Master III

Hi,

You can use ValueList() Function like this

Dimension : =ValueList('PAR7','PAR14','PAR30')

Expression :

Pick(Match(ValueList('PAR7','PAR14','PAR30'),'PAR7','PAR14','PAR30'),sum(If(ArrearsRentals>0,(CapitalArrears/ArrearsRentals),0)),Sum(If(ArrearsRentals>1,(CapitalArrears/ArrearsRentals),0)),
Sum(If(ArrearsRentals=3,(CapitalArrears/ArrearsRentals),If(ArrearsRentals>3,(CapitalArrears/ArrearsRentals)*2,0))))

Regards,

Antonio

Not applicable
Author

Thanks Anatonio for your great help.

Not applicable
Author

Hi , can I create this dimension in the coding part as PAR?

Tags
Community Browser