cancel
Showing results 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.

Helper I

## How do I use 2 different calculations for 1 column with several values?

Hi all,

I have a table of data that currently has one measure totalling up the amount for each business area, however for one business area i need to adjust the measure to calculate the total but miss out one column of data.

 Business Area Billable (£) Supplier (£) Fixed cost (£) Total (£) A 10000 9000 4500 23500 B 200000 100000 52000 352000 C 0 300000 20000 320000

The requirement is to calcualte the total for Business Areas A & B but not to include the Supplier(£) Value,

So the expected outcome would be as follows

 Business Area Billable (£) Supplier (£) Fixed cost (£) Total (£) A 10000 9000 4500 14500 B 200000 100000 52000 252000 C 0 300000 20000 320000
1 ACCEPTED SOLUTION
Community Support

Hi @James_Ma ,

You can create a measure as below to get it, please find the details in the attachment.

``````Total =
RETURN
IF (
_business IN { "A", "B" },
SUM ( 'Table'[Total (£)] ) - SUM ( 'Table'[Supplier (£)] ),
SUM ( 'Table'[Total (£)] )
)``````

Best Regards

Community Support Team _ Rena
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Community Support

Hi @James_Ma ,

You can create a measure as below to get it, please find the details in the attachment.

``````Total =
RETURN
IF (
_business IN { "A", "B" },
SUM ( 'Table'[Total (£)] ) - SUM ( 'Table'[Supplier (£)] ),
SUM ( 'Table'[Total (£)] )
)``````

Best Regards

Community Support Team _ Rena
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Announcements

#### 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

#### Power BI Monthly Update - April 2024

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

#### Fabric Community Update - April 2024

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

Top Solution Authors
Top Kudoed Authors