March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi Experts
How would you amend the following messure to make all those month that are 01/01 irrespective of year return zero value as opposed to the previous month value.
Meaure =
PREVIOUSMonth =
IF(CALCULATE(SUM(Orders[Sales]),
PREVIOUSMONTH(Orders[DDate]))=01/01,0,CALCULATE(SUM(Orders[Sales]),
PREVIOUSMONTH(Orders[DDate])))
Not working
Solved! Go to Solution.
Hi, @Invesco ;
If it is measure,
PREVIOUSMonth =
IF (
MONTH (max( Orders[DDate]) ) = 1
&& DAY ( max( Orders[DDate]) ) = 1,
0,
CALCULATE ( SUM ( Orders[Sales] ), PREVIOUSMONTH ( Orders[DDate] ) )
)
Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @Invesco ;
Try it.
PREVIOUSMonth =
IF (
MONTH ( Orders[DDate] ) = 1
&& DAY ( Orders[DDate] ) = 1,
0,
CALCULATE ( SUM ( Orders[Sales] ), PREVIOUSMONTH ( Orders[DDate] ) )
)
Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi Team Yalan is the above a messure or calculated column measure
Hi, @Invesco ;
If it is measure,
PREVIOUSMonth =
IF (
MONTH (max( Orders[DDate]) ) = 1
&& DAY ( max( Orders[DDate]) ) = 1,
0,
CALCULATE ( SUM ( Orders[Sales] ), PREVIOUSMONTH ( Orders[DDate] ) )
)
Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
User | Count |
---|---|
90 | |
89 | |
85 | |
73 | |
49 |
User | Count |
---|---|
167 | |
149 | |
93 | |
72 | |
58 |