Trying to get a measure that will sum sales for the month to day. So far I have the following expression, but it does not work:
(sum(aggr(sum(distinct{$<[completed_date.autoCalendar.Date]={">=$(=Date(max([completed_date])-30))"}>}(order_total)), order_id))
Instead, I get a rolling thirty day total. Any idea on how to get this to show Current MTD sales?
Also, probably very similar to that measure, I need to create a measure that will Sum last full week of sales:
(sum(aggr(sum(distinct{$<[completed_date.autoCalendar.Date]={"$(=Date(max([completed_date])-7))"}>}(order_total)), order_id))
not really working either. Any help is appreciated. Thanks in advance.