cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
dhanekula1996
Helper I
Helper I

Count number of rows in Total section

Hello all,
In table visualization I have a text column for the same column I want to show the count of rows in Total section. How Can i do that without adding a new value column?
@AlexisOlson  @amitchandak  @ValtteriN 

Ex: Desired Output:

         Column 1   Column 2
            A123        Fan
            B123         Bag
            C123         Phone

--------------------------------
Total =  3



1 ACCEPTED SOLUTION
smpa01
Super User
Super User

@dhanekula1996  you can write a measure like this

Measure = if(HASONEVALUE('Table'[Column 1]),CALCULATE(MAX('Table'[Column 2])),COUNTROWS('Table'))

 

smpa01_0-1639511725669.png

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!






New Animated Dashboard: Sales Calendar


View solution in original post

2 REPLIES 2
smpa01
Super User
Super User

@dhanekula1996  you can write a measure like this

Measure = if(HASONEVALUE('Table'[Column 1]),CALCULATE(MAX('Table'[Column 2])),COUNTROWS('Table'))

 

smpa01_0-1639511725669.png

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!






New Animated Dashboard: Sales Calendar


Thank you!!

 

 

Helpful resources

Announcements
Carousel_PBI_Wave1

2023 Release Wave 1 Plans

Power BI release plans for 2023 release wave 1 describes all new features releasing from April 2023 through September 2023.

Power BI Summit Carousel 2

Global Power BI Training

Make sure you register today for the Power BI Summit 2023. Don't miss all of the great sessions and speakers!

Thank you 2022 Review

2022 Monthly Feature Releases

We had a great 2022 with a ton of feature releases to help you drive a data culture.

Top Solution Authors
Top Kudoed Authors