Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
I calculated the MoM% with the "Quick Measure" option. The problem is that it adds an extra month that doesn't exist or assumes that the sales are zero in the next month. For example, I have data only until January 2024 and the used MoM% computes for February 2024 also (assumes that sales for February 2024 are zero then the MoM% this month is -100%). I would like to modify the measure to compute MoM% only until January 2024. I've tried a bunch of alternatives but nothing worked.
Solved! Go to Solution.
Hello @Anonymous , Please use below measure and it will remove current month.
Sales MoM% =
IF(
ISFILTERED('Sheet1'[Date]),
ERROR("Time intelligence quick measures can only be grouped or filtered by the Power BI-provided date hierarchy or primary date column."),
VAR __PREV_MONTH = CALCULATE(
SUM('Sheet1'[Sales]),
DATEADD('Sheet1'[Date].[Date], -1, MONTH)
)
RETURN
IF(SUM('Sheet1'[Sales]) <> BLANK(),DIVIDE(SUM('Sheet1'[Sales]) - __PREV_MONTH, __PREV_MONTH),BLANK())
)
If this post helps, then please consider accepting it as the solution to help other members find it more quickly. Thank You!!
Hello @Anonymous , Please use below measure and it will remove current month.
Sales MoM% =
IF(
ISFILTERED('Sheet1'[Date]),
ERROR("Time intelligence quick measures can only be grouped or filtered by the Power BI-provided date hierarchy or primary date column."),
VAR __PREV_MONTH = CALCULATE(
SUM('Sheet1'[Sales]),
DATEADD('Sheet1'[Date].[Date], -1, MONTH)
)
RETURN
IF(SUM('Sheet1'[Sales]) <> BLANK(),DIVIDE(SUM('Sheet1'[Sales]) - __PREV_MONTH, __PREV_MONTH),BLANK())
)
If this post helps, then please consider accepting it as the solution to help other members find it more quickly. Thank You!!
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 55 | |
| 34 | |
| 32 | |
| 19 | |
| 17 |
| User | Count |
|---|---|
| 75 | |
| 72 | |
| 38 | |
| 35 | |
| 25 |