cancel
Showing results for
Did you mean:

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Helper III

## Calculate with a filter on 2 fields

Hey All,

I would like to create a measure that shows me "how many of bytes are promoters"?

I created this measure:

BSS Promoter = COUNTX(FILTER(Cleaned, Cleaned[ID] = "Promoter"), Cleaned[Section.] = "bytes")

But that gives me a error.

Cleaned = table name

NPS = field

Section = field

So, how do I create a measure with a filter on 2 columns?

Thank you!

1 ACCEPTED SOLUTION
Helper III

I figured it out. I had to put calculate first.

so its:

BSS Promoter = CALCULATE(COUNTROWS(Cleaned),
FILTER(Cleaned, Cleaned[ID] = "Promoter"),
FILTER(cleaned, cleaned[Section.]="bytes"))
3 REPLIES 3
Helper III

I figured it out. I had to put calculate first.

so its:

BSS Promoter = CALCULATE(COUNTROWS(Cleaned),
FILTER(Cleaned, Cleaned[ID] = "Promoter"),
FILTER(cleaned, cleaned[Section.]="bytes"))
Super User

hi @e175429

Try like:
BSS Promoter =
COUNTROWS(
FILTER(
Cleaned,
Cleaned[ID] = "Promoter"
&&Cleaned[Section] = "bytes"
)
)
Helper III

When I try that, I get this error:

Announcements

#### Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

#### Power BI Monthly Update - August 2024

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

#### Fabric Community Update - August 2024

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

Top Solution Authors
Top Kudoed Authors