Forum Discussion
PREVIOUSMONTH
- 10 years ago
Finally you can use your measure:
SP= CALCULATE ( SUM ( Table1 [number ] ) ; previousMonth (CalendarTable [DATE ] ) )
This particular exession requires a date table related to the fact table. Are you using a date table?
Check out this link
http://www.mrexcel.com/forum/power-bi/842725-previous-month-date-dax-syntax.html
Thank you for answering!
i have a data table and a data fact, how ever no relationship was detected!
- Vvelarde10 years agoCommunity Champion
Hi, can you post a screenshot with tables and relationship?.
- Estefania8910 years agoNew Member
- Vvelarde10 years agoCommunity Champion
Hi Estefania89 you need a date Table with each day like a calendar.
To create a calendar table you can use:
Create a new Table (From Modeling)
CalendarTable=Calendar("01/01/2015";31/12/2016") you can change the dates according to your tables.
Next, create a relationship between date columns on your tables and Calendar Table.