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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

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
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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