Forum Discussion

EllieDudman's avatar
EllieDudman
Copper Contributor
Nov 14, 2023

IF Function

Please could someone help me with the correct IF Function I need to return the following in the % variance column:

 

If 2022 is blank or 0 return 100%

If 2023 and 2022 are blank or 0 return 0%

Otherwise return the result of the formula - variance column divided by 2022

 

 20232022Variance% Variance
A55055100%
B085(85)-100%
C0000%

 

Thank you

  • Detlef_Lewin's avatar
    Detlef_Lewin
    Silver Contributor

    EllieDudman 

    The formula is:

    =[@Variance]/[@2022]

    Everything else is inventing new mathematics.

     

    Or you could trap the error:

    =IFERROR([@Variance]/[@2022],"not computable")

     

Resources