
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Like to Like sales comparison
Hi All,
Hope everyone is doing great.
I need help on calculating like to like sales comparison from last year to this year. Main criteria is i need to compare the sales for products which got sales in both years that means sales value in last year and sales value this year should not be zero (0).
I have to use the above calculation to derive top 5 and bottom 5 performing products (YOY % Change)in a bar chart.
I have used the below logic but not able to include "sales value in last year and sales value this year should not be zero " as the logic was out of rank function it is not using the logic to avoid those products which have zero value in either year.
aggr(if((rank((Sum({<CurYTDFlag={1}>}SalesValue)-Sum({<LastYTDFlag={1}>}SalesValue))/fabs(Sum({<LastYTDFlag={1}>}SalesValue)),4)<=5
or rank(-(Sum({<CurYTDFlag={1}>}SalesValue)-Sum({<LastYTDFlag={1}>}SalesValue))
/fabs(Sum({<LastYTDFlag={1}>}SalesValue)),4)<=5) and Sum({<CurYTDFlag={1}>}SalesValue)<>0
and Sum({<LastYTDFlag={1}>}SalesValue)<>0,WP_ProductDescription),WP_ProductDescription)
Kindly help in this regard.
Thanks,
Nani

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Would you be able to share a sample with expected output you are looking to get?
