Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
New to Qlik. I need to subtract 2 columns in a pivot table. These 2 columns are filtered by a date and change based on the user input. I need to add a new column named 'Delta' that subtracts column 2 and 1 for all rows no matter what 2 dates are entered.
Result:
.
.
.
Hi, in date dimension you can check the option to show total, and using SecondaryDimensionality() to change the totals expression, and use set analysis to substract the amount of the min date to the max date.
In example if the current expresion is Sum(Amount), using totals it could be:
If(SecondaryDimensionality()=0
,Sum({<Date={'$(=Date(Max(Date)))'}>} Amount)-Sum({<Date={'$(=Date(Min(Date)))'}>} Amount)
,Sum(Amount)
)