Forum Discussion
Estefania89
10 years agoNew Member
PREVIOUSMONTH
Hello! Attempt to calculate the sales of the previous month using this function:
SP= CALCULATE ( SUM ( Table1 [number ] ) ; previousMonth (Table 2 [DATA ] ) )
However, the function does not return values
Finally you can use your measure:
SP= CALCULATE ( SUM ( Table1 [number ] ) ; previousMonth (CalendarTable [DATE ] ) )
8 Replies
- kcantorCommunity Champion
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
- Estefania89New Member
Thank you for answering!
i have a data table and a data fact, how ever no relationship was detected!
- VvelardeCommunity Champion
Hi, can you post a screenshot with tables and relationship?.