Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone, I need help creating an expression for Change in tickets year-to-year and showing the percentage change. Adding table below for reference. Thank you in advance.
Hi, @dnt503
Try working with the function above.
see example:
Value
sum (ticket)
-
Above(sum(ticket))
===============
percentage %
(
sum(ticket)
/
Above(sum(ticket))
)-1
qlik documentation help function above:
https://help.qlik.com/pt-BR/sense/November2023/Subsystems/Hub/Content/Sense_Hub/ChartFunctions/Inter....
Regarts, Matheus
To do all the logic in the chart you can use the above() function to grab the previous line's value:
Current Row Value: Sum([Number of Tickets]))
Previous Row Value: Above(Sum([Number of Tickets]),1)
Difference: (Above(Sum([Number of Tickets]),1) - Sum([Number of Tickets]))
% Difference:
(Above(Sum([Number of Tickets]),1) - Sum([Number of Tickets]))
/
Above(Sum([Number of Tickets]),1)