Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Number.Mod Bug

Number.Mod doesn't return that same than it's corrsponding functions in Excel and DAX when negative numbers are involved. I find this really bad.

Please change.

 

Current workaround:

(number, divisor) => if number>0 then number-Number.RoundDown(number/divisor,0) else Number.Abs(divisor)+number
Status: Accepted
Comments
v-haibl-msft
Microsoft Employee

@ImkeF

 

I can repro the same issue as you. I’ve reported it internally to Power BI Team: CRI 46952686
I’ll post here once I get any update about it.

 

Best Regards,
Herbert

Vicky_Song
Impactful Individual
Status changed to: Accepted
 
v-haibl-msft
Microsoft Employee

@ImkeF

 

I’ve got response from the Product Team.

 

We do not intend M to copy either Excel or DAX semantics. M has its own semantics and the current behavior is by design.

 

Best Regards,
Herbert