Dear Qlik Master,
I have a requirement that have to show Growth trend by Year.
That have formula : [YTD Sales]-[Prev YTD Sales]
I've created an expression that show correct result in summary chart like Speedo.
But when i want to add Year Dimension, it shows different result.
My result is like below :
with Curr Sales expression :
sum(
{<
FLAG_TRANS={'Item_Sales_Detail'},
Year={'$(=max(Year))'},
MonthDay={'<=$(=max( {<FLAG_TRANS={'Item_Sales_Detail'},Year={'$(=max(Year))'}>} MonthDay))'},
Quarter=,Month=,Week=,Day=
>}
ITEMBASEAMOUNT)
and Prev Sales expression :
sum(
{<
FLAG_TRANS={'Item_Sales_Detail'},
Year={'$(=max(Year)-1)'},
MonthDay={'<=$(=max( {<FLAG_TRANS={'Item_Sales_Detail'},Year={'$(=max(Year))'}>} MonthDay))'},
Quarter=,Month=,Week=,Day=
>}
ITEMBASEAMOUNT)
And the result that user expected is :
What's wrong with my expression?
Please help.
Thank you,
Best Regards