Don't miss your chance to take exam DP-600 or DP-700 on us!
Request nowLearn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
I don't understand how the time intelligence functions are working.
I created two measures
Sales July 2015 = CALCULATE(SUM(Revenue), DATESBETWEEN(Dates[Date], DATE(2015,7,1), DATE(2015,7,31)))
Sales Previous Month = CALCULATE([Sales July 2015], PREVIOUSMONTH(Dates[Date]))
Problem: Sales July 2015 gives the same result than Sales Previous Month
If I do: Sales Previous Month = CALCULATE([Sales July 2015], PREVIOUSMONTH(DATESBETWEEN(Dates[Date], DATE(2015,7,1), DATE(2015,7,31))))
it works fine.
I don't get how the time intelligence functions are working. What am I missing??
Solved! Go to Solution.
PREVIOUSMONTH returns all dates from the previous month based on the first value in the dates column, so I am guessing that your first date is August so it is dumb luck that it is the same as your July?
Why don't you use DATEADD to shift the dates 1 months back?
Try this:
Sales Previous Month = CALCULATE([Sales July 2015], DATEADD( Dates[Date], -1, MONTH ) )
Best regards
Dominik Petri.
PREVIOUSMONTH returns all dates from the previous month based on the first value in the dates column, so I am guessing that your first date is August so it is dumb luck that it is the same as your July?
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Check out the February 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 50 | |
| 40 | |
| 37 | |
| 14 | |
| 14 |
| User | Count |
|---|---|
| 85 | |
| 69 | |
| 38 | |
| 29 | |
| 27 |