Forum Discussion
Anonymous
3 years agoNot applicable
IFERROR Problem
Formula is very simple it is a sum of variables and then multiplies by a ratio I have this meausure to compute Total Rev. I am using the IFERROR to counter NAN problem in the calculation. Howeve...
- 3 years ago
instead of IFERROR use DIVIDE - it handles these scenarios gracefully.
Anonymous
3 years agoNot applicable
Hi Anonymous ,
Plesae try this measure.
Total_Rev2 =
(
(
SUM ( '1.Orders (fact)'[CHARGES] ) + SUM ( '1.Orders (fact)'[XCHARGES] )
- SUM ( '1.Orders (fact)'[FSC_CHARGES] )
)
* IF (
AND (
SUM ( '1.Orders (fact)'[FUNCTIONAL_AMT] ) = 0,
SUM ( '1.Orders (fact)'[TOTAL_CHARGES] ) = 0
),
0,
DIVIDE (
SUM ( '1.Orders (fact)'[FUNCTIONAL_AMT] ),
SUM ( '1.Orders (fact)'[TOTAL_CHARGES] )
)
)
+ ( SUM ( '1 Order Interliner'[AMOUNT] ) )
)
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum