Forum Discussion
Compare Feature Sales with Previous Year Feature Sales
Hi Baskar,
Thank you for your offer for help :)
For example you have the following table. You can construct and a calendar table based on the Reservation Date.
| Input Date | Reservation Date | Revenue |
| 01/01/2015 | 02/02/2016 | 250 |
| 10/05/2015 | 03/04/2016 | 100 |
| 11/11/2015 | 10/12/2016 | 300 |
| 27/12/2015 | 11/11/2016 | 500 |
| 03/04/2016 | 10/10/2017 | 100 |
| 05/10/2016 | 05/05/2017 | 400 |
| 20/12/2016 | 23/12/2017 | 585 |
| 23/12/2016 | 10/10/2017 | 100 |
Thus the goal is to have a graph with 2 bars side-by-side were if you see the data asOf today 23/12/2016 you should see the details by month but total wise will be:
- asOf 23/12/2016 (Input Date) - Result is Reservation dates 2017 with total revenue=1185
- Based on the above asOf date the previous year (thus 23/12/2015) - Result is Reservation Dates 2016 with Revenue = 650
Thank you in advance.
Hi there,
From your table looks like you just need to calcualte YTD Revenue and here is what you can use for that:
YTD Sales = TOTALYTD(SUM(Sales[Revenue]),'Calendar-1'[Date])
I assumed you already have calendar table and linked to Sales Table on Input Date, make sure relationship is single as shown below.
Results for two different dates
Hope it is helpful, let me know if need further assistance.