Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Good day,
I am sure this is not a hard thing to do but I cant seem to find a way to do it.
When creating a KPI with 2 measures I want the second 1 to show the previous year.
So when I select 2019 Financial year. I want the second measure to show 2018.
See here my KPI and the Measure
Thank you
Hello Werner,
This can be done by using set analysis. If you select one year and the expression for the first measure = sum(sales), the expression for the second measure can be :
sum({$<Year={$(=only(Year)-1)}>}Sales)
Which means the sum of sales is calculated for the selected year minus one. This will only work if there is exactly one year selected, if you always want to show the sales of last year you could use:
sum({$<Year={$(=year(today())-1)}>}Sales)
(and for the current year it would be sum({$<Year={$(=year(today()))}>}Sales)
Greetings,
Tim Wensink
HI,
Use this in your set analysis expression
Year Field= {"$(=Max(Year Field)-1)"}
Hello Werner,
This can be done by using set analysis. If you select one year and the expression for the first measure = sum(sales), the expression for the second measure can be :
sum({$<Year={$(=only(Year)-1)}>}Sales)
Which means the sum of sales is calculated for the selected year minus one. This will only work if there is exactly one year selected, if you always want to show the sales of last year you could use:
sum({$<Year={$(=year(today())-1)}>}Sales)
(and for the current year it would be sum({$<Year={$(=year(today()))}>}Sales)
Greetings,
Tim Wensink
HI,
Use this in your set analysis expression
Year Field= {"$(=Max(Year Field)-1)"}