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

Prepping for a Fabric certification exam? Join us for a live prep session with exam experts to learn how to pass the exam. Register now.

Reply
WaleedBinAfzal
Frequent Visitor

How to Use Count for getting total from one column against other column?

Hi All,

I am new to power bi and need some help. I have a table of opportunities in which one column has name principals and one is with name status of the opportunity having values like Won, Lost, Open. Now i want to get the total count of Won Opportunities against each principal. How can i do this? Any help would be highly appreciable.

1 ACCEPTED SOLUTION
v-juanli-msft
Community Support
Community Support

Hi @WaleedBinAfzal

In Modelling->New Measure, create a new measure

Measure = CALCULATE(COUNT(Sheet1[status]),FILTER(ALLEXCEPT(Sheet1,Sheet1[principals]),[status]="Won"))

4.png

 

 

Best Regards

Maggie

View solution in original post

4 REPLIES 4
Ashish_Mathur
Super User
Super User

Hi,

 

Drag Principals to the row labels and write this measure

 

=CALCULATE(COUNTROWS(Sheet1),sheet1[status]="Won")

 

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
v-juanli-msft
Community Support
Community Support

Hi @WaleedBinAfzal

In Modelling->New Measure, create a new measure

Measure = CALCULATE(COUNT(Sheet1[status]),FILTER(ALLEXCEPT(Sheet1,Sheet1[principals]),[status]="Won"))

4.png

 

 

Best Regards

Maggie

Hi 

zlokesh
Resolver I
Resolver I

In Fields visualization.

Under Details select,  Priciple Name

And under values select Count of Opprtunity.

Helpful resources

Announcements
PBIApril_Carousel

Power BI Monthly Update - April 2025

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

Notebook Gallery Carousel1

NEW! Community Notebooks Gallery

Explore and share Fabric Notebooks to boost Power BI insights in the new community notebooks gallery.

April2025 Carousel

Fabric Community Update - April 2025

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