Forum Discussion
DAX EXCLUDE
Hi!
I want to exclude some of my rows when using a simple "COUNTROWS" function in Power BI desktop.
What i would like to get help with is a DAX formula for this that excludes specific rows that contains a ordernumber (this is a column in the table which i would like to count the number of rows in) that starts with a specific capital letter.
Any suggestions?
Thanks in advance!
/Johan
- Anonymous7 years agoHope i understand correctly,
COUNTROWS(FILTER(table;left(column;1)="T")
5 Replies
- selimovd
Most Valuable Professional
Maybe you can post some samlple data? This would make it a lot easier to help you
- Torudd-55Frequent Visitor
Hi, see the picture below for an example of the data in the table. What i want is to count all of the rows whitin the table but exclude Order No_ that starts with tha capital letters R and M. In the picture these doesn't show, only the orders with a "T" as starting Letter. Hope this will help you help me. :)
Thanks!
- AnonymousNot applicableHi, does
COUNTROWS(FILTER(table;column <>ordernr))
Or
COUNTROWS(
FILTER(table;column <>ordernr||column<> ordernr)
For excluding multiple orders.
Gives you the desired outcome?- Torudd-55Frequent Visitor
No, unfortunatly not. I posted some example data in another reply if that can help you aswell?
Thanks for trying!
/Johan
- AnonymousNot applicableHope i understand correctly,
COUNTROWS(FILTER(table;left(column;1)="T")