2 Replies Latest reply: Nov 30, 2017 11:18 PM by Shraddha Gajare

# How to use a formula as the dynamic limit for conditional color in KPI

Hello to all!

I am a new user of Qlik Sense.

I have created a KPI for current month compared to last month and now I want to use as the dynamic limit for conditional color the value of last month (using the last month formula), but the value is the sum of all value.

what am I doing wrong?

These are the formulas:

current month: Sum( { \$< [Date / EndTest.autoCalendar.InMTD]={1}, [Date / EndTest.autoCalendar.MonthsAgo]={0} > } [Number of Tests] )

last month: Sum( { \$< [Date / EndTest.autoCalendar.InMTD]={1}, [Date / EndTest.autoCalendar.MonthsAgo]={1} > } [Number of Tests] )

• ###### Re: How to use a formula as the dynamic limit for conditional color in KPI

If possible share sample app

• ###### Re: How to use a formula as the dynamic limit for conditional color in KPI

I guess for Last Month it should be

Sum( { \$< [Date / EndTest.autoCalendar.InMTD]={0}, [Date / EndTest.autoCalendar.MonthsAgo]={1} > } [Number of Tests] )