Forum Discussion
WaelTalaat79
Helper I
4 years agoHi dear
I am trying to calculate a if condition for previousmonth and I got this message MdxScript(Model) (13, 76) Calculation error as attached photo
Fowmy
Super User
4 years agoWaelTalaat79
Modify your meusre as follows:
= IF( MONTH( PREVIOUSMONTH( 'Dates'[Date].[Date] ) ) = 12 , 0 , 1 )
- WaelTalaat794 years ago
Helper I
error message MdxScript(Model) (13, 72)
= 12 mean December so should I select MonthNo instead of date
- Fowmy4 years ago
Super User
WaelTalaat79
Where/what are you using this measure? Please share screenshot of the calcualtion- WaelTalaat794 years ago
Helper I
- this the calculated formula
- so I need the manthly impact by subtracting the calculated month - previous month
- but the problem in month of Jan. that considering the previous month as December that should be always Zero and the previous month fromula bring December value as normal fromula
- so I need that if the previous month is December put zero if not apply the fromula
And this is the previous month fromula