Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello All,
I am working on Retail application. I have shown total sales of Product's category. Now What I want, When ever I selects year, It should give me comparison of selected year and previous year w.r.t to product's category.
Thanks in Advance
Regards,
Raj
If you take Year as dimension, you can try expression like:
=Sum({<Year={">=(=Max(Year)-1)"}> Amount}
Or, for detailed discussion and understanding see this recent blog post: http://community.qlik.com/blogs/qlikviewdesignblog/2014/03/03/ytd
hi try this. it will give last year and current year comparison
( sum( {<Year={$(=Max(Year))}>} totlasales) - sum({<Year={$(=Max(Year)-1)}>} totalsales))/sum( {<Year={$(=Max(Year)-1)}>} totalsales)
HI,
Try like this
Dimension = Year
Expression = Sum({<Year={">=(=Max(Year)-1)"}> Amount)
OR
= Sum({<YearDimensionName=, MonthDimensionName=, QuarterDimensionName=,
DateDimensionName{">=$(=YearStart(Max(DateDimensionName), -1))"}> Amount)
Hope this helps you.
Regards,
Jagan.
Jagan,
Its not working.
Regards,
Raj
Hi Balraj,
Can you attach some sample file?
Regards,
Jagan.