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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
EdMbu
Frequent Visitor

Count number of "Left" in this measure

Lost Customers = IF([Total_amount_exclude_vat_]>0&&'All measure'[Last Period Revenue]<=0, "Left", BLANK())

Can someone explain to me how I can count the row number of this measure and filter the number of "Left". this measure is in a measure table. Thanks 

1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

To count the rows of a table you need to have a table first. 

 

Create a table variable to SUMMARIZE over the customer IDs. Use ADDCOLUMNS to compute if they left or not. FILTER the result by the ones that left.  Do a COUNTROWS over that result. That's what your measure should return.

View solution in original post

2 REPLIES 2
EdMbu
Frequent Visitor

Thanks. its work

lbendlin
Super User
Super User

To count the rows of a table you need to have a table first. 

 

Create a table variable to SUMMARIZE over the customer IDs. Use ADDCOLUMNS to compute if they left or not. FILTER the result by the ones that left.  Do a COUNTROWS over that result. That's what your measure should return.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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