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
LeeM
New Member

Count number of instances aginst each entry

Hi,

I'm a new user to Power BI and trying to replicate some functionality that I use in Excel.

Using an existing Excel table which has entries of A1:A10.

I use the following =Countif(A:A,A1) in cell B1, which I then copy down to the end of the data B10

Against each row (B1:B10) it would then show how many times the text in the referenced cell appears in the array.

I want to try and replicate this in power query.

I've searched and searhced but can't find anything that gives me the individual answers.

Many thanks Lee

 

LeeM_0-1662561431661.png

 

 

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

Hi @LeeM ,

 

Please create the new column.

 

Column = COUNTROWS(FILTER('Table','Table'[Name] = EARLIER('Table'[Name])))

vkkfmsft_0-1662604842410.png

 

Best Regards,
Winniz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-kkf-msft
Community Support
Community Support

Hi @LeeM ,

 

Please create the new column.

 

Column = COUNTROWS(FILTER('Table','Table'[Name] = EARLIER('Table'[Name])))

vkkfmsft_0-1662604842410.png

 

Best Regards,
Winniz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

serpiva64
Super User
Super User

Hi,

can you post an exemple in excel?

Hi serpiva64, I've updated the original post with an example. Thanks Lee

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.

Top Solution Authors
Top Kudoed Authors