This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreGet Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.
Hello good people,
Need your help.
I have the following table.
All the columns are calculated columns. I want to have a "Total" which excludes "Gross Profit". Currently it is counting the "Gross Profit" inside the "Total". I want to keep it excluded. Please help.
Solved! Go to Solution.
Hi @Anonymous
You can adjust the below Measure to get the required result.
Sales Total without Contoso =
VAR __totalWithoutContoso =
CALCULATE(
[Sales],
KEEPFILTERS(
NOT 'Product'[Brand] = "Contoso"
)
)
RETURN
IF(
HASONEVALUE( 'Product'[Brand] ),
[Sales],
__totalWithoutContoso
)
@Anonymous , Try like
Total New =calculate([Total],Table[MOH COA Level 6]!="Gross Profit")
or
Total New = if(isfiltered(Table[MOH COA Level 6]),[Total],calculate([Total],Table[MOH COA Level 6]!="Gross Profit"))
refer
https://powerpivotpro.com/2013/03/hasonevalue-vs-isfiltered-vs-hasonefilter/
Hi @Anonymous
You can adjust the below Measure to get the required result.
Sales Total without Contoso =
VAR __totalWithoutContoso =
CALCULATE(
[Sales],
KEEPFILTERS(
NOT 'Product'[Brand] = "Contoso"
)
)
RETURN
IF(
HASONEVALUE( 'Product'[Brand] ),
[Sales],
__totalWithoutContoso
)
Thanks a lot man. Your solution is precise and to the point 😀
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 25 | |
| 24 | |
| 22 | |
| 21 | |
| 19 |
| User | Count |
|---|---|
| 51 | |
| 48 | |
| 44 | |
| 21 | |
| 21 |