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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
instdes
Frequent Visitor

Multiplying Values IF Value Exists in One Column

I currently have a measure that multiplies two column numbers together:

 

Formula = CALCULATE(SUM('Employee'[Effort]) * SUM('Employee'[Completion]))
 
however sometimes the "Completion" column does not have a value so instead of ignoring the null value, it will multiple by 0 and not give me a measure.  Any help would be great appreciated for my IF formula that does not seem to be working correctly:
 
FormulaNull = CALCULATE(SUM('Employee'[Effort]) * IF(SUM('Employee'[Completion]), BLANK(), (SUM('Employee'[Completion]))
1 ACCEPTED SOLUTION

Thank you for your response.  Yes, I ended up using this formula:

 

FormulaNull = CALCULATE(SUM('Employee'[Effort]) * IF(SUM('Employee'[Completion]) = BLANK(), 1, SUM('Employee'[Completion])))

View solution in original post

3 REPLIES 3
v-jingzhang
Community Support
Community Support

Hi @instdes 

 

You can try this measure. 

FormulaNull =
IF (
    ISBLANK ( SUM ( 'Employee'[Completion] ) ),
    BLANK (),
    SUM ( 'Employee'[Effort] ) * SUM ( 'Employee'[Completion] )
)

 

Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.

Thingsclump
Resolver V
Resolver V

Hi @instdes 

 

Did you try using ISBLANK along with IF? If it's blank, return 1. If not, then return actual value.

 

Thanks

 

 

Thank you for your response.  Yes, I ended up using this formula:

 

FormulaNull = CALCULATE(SUM('Employee'[Effort]) * IF(SUM('Employee'[Completion]) = BLANK(), 1, SUM('Employee'[Completion])))

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors