Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I am a newbie in Qlik.
I have a pivot table with a column that calculates a % between current row-column1 and above row-column1.
My problem is that I want to evaluate that expression only when the user expands all dimensions, I mean the last level
(because if the pivot table is collapsed all, the comparison is meaningless).
The expression is like this:
(
sum( if(YEARDATE<= v_maxYear, netfat, 0))
-
above(sum( if(YEARDATE <= v_maxYear, netfat, 0)))
)
/
above(sum( if(YEARDATE <= v_maxYear, netfat, 0)))
Is there a way to know if we are in the last level (with "expand all")?
Thanks!
Sort of. There's a dimensionality() function that basically tells you how many dimensions are displayed at the left, and a secondarydimensionality() function that tells you how many dimensions are displayed at the top. That won't tell you if the whole chart is fully expanded, but for any given cell, you could see if that cell is being displayed at the lowest possible level. Like if you have five dimensions, if dimensionality() + secondarydimensionality() = 5, you're at the lowest level of detail for that cell, so then it might be appropriate to do your calculation.
Sort of. There's a dimensionality() function that basically tells you how many dimensions are displayed at the left, and a secondarydimensionality() function that tells you how many dimensions are displayed at the top. That won't tell you if the whole chart is fully expanded, but for any given cell, you could see if that cell is being displayed at the lowest possible level. Like if you have five dimensions, if dimensionality() + secondarydimensionality() = 5, you're at the lowest level of detail for that cell, so then it might be appropriate to do your calculation.
Thank you very much, this solved my problem!