Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!
Hello,
I am new to Power BI and need some help setting up a measure. I want to calculate MOI (months of inventory)
The result you see in the above picture may vary based on the past number which is selected in a drop down box.
Total year: Sales for this part number over the last 12 months
Monthly usage: Total year divided by 12
On hand: current inventory
Customer order: open customer orders
Purchase order: open purchase orders
MOI: months of inventory
Either of these fields can show a blank as a result of the part number selected.
Currently my fomula shows:
Solved! Go to Solution.
The reason you are getting 1.78 is because it is calculating (168 - 0 +72) from right to left 0 + 72 = 72 then it subtracts 72 from your 168 and you get 96 divided by 54. You can put additional parenthesis to enclose even further the data between 168-0 so it does this calculation before it adds 72 or see below and use calculate or variables.
Example 1
MOI=
It worked like a charm. Thank you very much for pointing this out and providing a solution😀😀
The reason you are getting 1.78 is because it is calculating (168 - 0 +72) from right to left 0 + 72 = 72 then it subtracts 72 from your 168 and you get 96 divided by 54. You can put additional parenthesis to enclose even further the data between 168-0 so it does this calculation before it adds 72 or see below and use calculate or variables.
Example 1
MOI=
It worked like a charm. Thank you very much for pointing this out and providing a solution😀😀
The Power BI Data Visualization World Championships is back! It's time to submit your entry.
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 56 | |
| 42 | |
| 39 | |
| 23 | |
| 21 |
| User | Count |
|---|---|
| 144 | |
| 106 | |
| 63 | |
| 38 | |
| 31 |