Forum Discussion
MONA4980
1 year agoFrequent Visitor
LAST MONTHS SALES
Hello, I am really new to Power BI and DAX. I am trying to get MOM data and have to first get my profit from last month. Before I throw it out there know that I have a table that uses the calenda...
- 1 year ago
Hi,
1. Mark your calendar table as Date table.
2. Use time-based functions like 'PARALLELPERIOD' on your Calendar table.That said, update your Measure to,
LAST MONTH PROFIT =
CALCULATE(
SUM('ORDERS'[PROFIT]),
USERELATIONSHIP('Calendar'[Date], 'ORDERS'[DISPDATE]),
PARALLELPERIOD('Calendar'[Date], -1, MONTH)
)Hope this works for you:)
MONA4980
1 year agoFrequent Visitor
Thank you for the quick reply. I clicked on your first link, time inteligence, and it did not work.
I will check out the "hard way"