Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
how can i find sum of sales over year to date,quarter to date and month to date after picking any saledate..pls provide the steps.
Hi Monica,
here it is
sum( if (DYear=AYear and DMonth<=AMonth, amt))
in this example your table "ADates" is not link to the model
best reagrds
chris
hi..what is Dyear and Ayear in this
This is an example you have to set according to your own script
Let us say your Sales table contains dates infos like DYear, Dmonth, DWeek....
and a table for Dates which contains AYear, AMonth, AWeek and so on. This table is not attached to the model. So you can compare the Sales dates according the dates you selected in table Dates
I hope it's clearer.
best regards
chris
Try these
YTD
SUM(
{<Date = {">=$(=DATE(FLOOR(YEARSTART($1))))<$(=DATE(FLOOR($1)))"}>}Sales) |
QTD
SUM({<
Date = {">=$(=DATE(FLOOR(QUARTERSTART($1))))<$(=DATE(FLOOR($1)))"} |
>}Sales)
MTD
SUM){<
Date = {">=$(=DATE(FLOOR(MONTHSTART($1))))<$(=DATE(FLOOR($1)))"} |
>}Sales)
Thnx alan, bt its not working..no data comin.
try this for YTD and let me know if that works
sum({$<Year = {$(=only(Year))}, Month = {"<=$(=max(Month))"}>} Sales) |
no its still not working..result is zero again
try this
YTD this Year
SUM({<Year={$(=MAX(TOTAL Year))}>}Sales)
YTD last Year
SUM({<Year={$(=MAX(TOTAL Year)-1)}>}Sales) |
that is i want to select one date and depending on that it will show me the sales for the that selected date from the starting of that year .
I want this for any particaular date when it is selected.............
Plz tell me if any one knows it.