Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I am trying count the number of rows in a table if a column CONTAINS certain text.... I have created a list of the items (13 items) which i need to check against the column to identify it it contains the data.
For example:
Search Column1 to see if it CONTAINS "egg", "apple", rice"
and count the rows that return.
Solved! Go to Solution.
@Anonymous
Try it like this.
Item Count =
CALCULATE (
COUNTROWS ( YourTable ),
'YourTable'[Column1] IN { "egg", "apple", "rice" }
)
=calculate (countrows(tablename), tablename[column] IN { "egg","apple","rice"})
Did I answer your question? If so, please mark my post as a solution!
Proud to be a Super User!
@Anonymous
Try it like this.
Item Count =
CALCULATE (
COUNTROWS ( YourTable ),
'YourTable'[Column1] IN { "egg", "apple", "rice" }
)
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 37 | |
| 37 | |
| 33 | |
| 32 | |
| 29 |
| User | Count |
|---|---|
| 130 | |
| 88 | |
| 82 | |
| 68 | |
| 64 |