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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
cocoloco79
Helper III
Helper III

Calculated Column, Need help with formula please

Hi everyone,
 
I'm trying the formula below, but if crop is not "sweet corn" the formula should return Prod[Crop.Units] but instead it returns blank cells. It does calcualte correctly when the IF condition is filled. Can someone help with this?
 
 
FME = IF(Prod[Crop] ="Sweet Corn",IF( and (Prod[OuterProduct] ="PROC - WWFME - Bean Carrot Corn - Woolworths FME 8 x 350g - Cartons",Prod[Boxes]*Prod[qtyinner]),Prod[Boxes x qtyinner],Prod[Crop.Units]))
1 ACCEPTED SOLUTION
DallasBaba
Skilled Sharer
Skilled Sharer

@cocoloco79 Can you try

 

FME =
IF(
    Prod[Crop] = "Sweet Corn",
    IF(
        AND(
            Prod[OuterProduct] = "PROC - WWFME - Bean Carrot Corn - Woolworths FME 8 x 350g - Cartons",
            Prod[Boxes] * Prod[qtyinner]
        ),
        Prod[Boxes x qtyinner],
        Prod[Crop.Units]
    ),
    Prod[Crop.Units]
)

 

OR

 

 

FME = IF(
    Prod[Crop] = "Sweet Corn",
    IF(
        AND(
            Prod[OuterProduct] = "PROC - WWFME - Bean Carrot Corn - Woolworths FME 8 x 350g - Cartons",
            Prod[Boxes] * Prod[qtyinner]
        ),
        Prod[Boxes x qtyinner],
        IFBLANK(Prod[Crop.Units], 0)
    )
)

 

 

Let me know if this works for you. @ me in replies, or I'll lose your thread!!!  
If this post helps, please consider Accepting it as the solution to help others find it more quickly. 

 

Best Regards,
Dallas.
Thanks
Dallas

View solution in original post

2 REPLIES 2
DallasBaba
Skilled Sharer
Skilled Sharer

@cocoloco79 Can you try

 

FME =
IF(
    Prod[Crop] = "Sweet Corn",
    IF(
        AND(
            Prod[OuterProduct] = "PROC - WWFME - Bean Carrot Corn - Woolworths FME 8 x 350g - Cartons",
            Prod[Boxes] * Prod[qtyinner]
        ),
        Prod[Boxes x qtyinner],
        Prod[Crop.Units]
    ),
    Prod[Crop.Units]
)

 

OR

 

 

FME = IF(
    Prod[Crop] = "Sweet Corn",
    IF(
        AND(
            Prod[OuterProduct] = "PROC - WWFME - Bean Carrot Corn - Woolworths FME 8 x 350g - Cartons",
            Prod[Boxes] * Prod[qtyinner]
        ),
        Prod[Boxes x qtyinner],
        IFBLANK(Prod[Crop.Units], 0)
    )
)

 

 

Let me know if this works for you. @ me in replies, or I'll lose your thread!!!  
If this post helps, please consider Accepting it as the solution to help others find it more quickly. 

 

Best Regards,
Dallas.
Thanks
Dallas

@DallasBaba Legend, your first solution worked!!! Thanks a lot!

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors