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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
Warner
New Member

Measure to count multiple text value from one column

Hi All, 

 

I am trying to create a measure or measures, which can give me an overall figure for each text value that appears within my dataset. 

 

I have one column that has a range of text values in it. Which summaries some factors that i am trying to count. 

 

For example: 

 

Client IDFactors
1100000000AA
1100000001AA, AB
1100000002AA, AB, AC
1100000003AA

 

What i am trying to do is create a measure that can count all of these in one go. Instead of what i am doing now which would be: 

 

Test = CALCULATE(COUNTROWS('Contact data'),FILTER('Contact data','Contact data'[Factors]="AA"))
Test = CALCULATE(COUNTROWS('Contact data'),FILTER('Contact data','Contact data'[Factors]="AA, AB"))
 
and then creating a new measure to add these up. 
 
This is becasue the data has 655 rows and i dont want to have to create a measue every time a new option within the text field changes? 
 
So from the above example i would want the total for the measure to be 3? 
 
 
1 ACCEPTED SOLUTION
v-yalanwu-msft
Community Support
Community Support

Hi, @Warner ;

You could modify it by the following:

Test = CALCULATE(COUNTROWS('Contact data'),FILTER(ALL('Contact data'),'Contact data'[Factors] in {"AA","AA, AB"}))

The final output is shown below:

vyalanwumsft_0-1633328983644.png

Best Regards,
Community Support Team_ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-yalanwu-msft
Community Support
Community Support

Hi, @Warner ;

You could modify it by the following:

Test = CALCULATE(COUNTROWS('Contact data'),FILTER(ALL('Contact data'),'Contact data'[Factors] in {"AA","AA, AB"}))

The final output is shown below:

vyalanwumsft_0-1633328983644.png

Best Regards,
Community Support Team_ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

lbendlin
Super User
Super User

Test = DISTINCTCOUNT('Contact data'[Factors])

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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