I would like to know if the following is possible in Tableau:
Let say I have a 1 year data of sales starting from Jan 2013 to Dec 2013. In the dashboard, there should be a score card showing the following:
Last 7 day sales
I was able show the YTD and MTD sales. However, I am having difficulty showing the Last 7 day sales. The last 7 day sales should change its value everytime the date filter is changed by the user.
Hope to hear from you soon.
The following calculation can be used if you're trying to find the last 7 days relative to today:
if [Order Date]>=dateadd('day', -7, today()) then Sales end
If relative to the latest date in the view, change the calculation to be similar to:
if max([Order Date])>=dateadd('day', -7, window_max(max([Order Date]))) then sum(Sales) end
Hope this helps!
Become a Viz Whiz on the Forums!
Support the Community and master Tableau.
Retrieving data ...