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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
Syndicate_Admin
Administrator
Administrator

COUNT in a table per row

Hello everyone!
I recently started a project where I have the following table loaded in DirectQuery mode:
data_operador1_0-1642079910409.png

Then I need to add a column in which I make the division of "SalesSale Count" by a DISTINCTCOUNT(Table[DATE]), but I think it cannot, so I have created my own column, called "Manual SalesSaleTh Count" using the COUNT(Table[SalesDate]) function the column created is as follows: (Option "Unsummarised" in the values of the table)

data_operador1_1-1642080467887.png

Can you think of any method or way to be able to make the division?
Thank you very much in advance.
1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Syndicate_Admin , A new column = DISTINCTCOUNT(Table[DATE])

will give grand total

in measure DISTINCTCOUNT(Table[DATE]) will give row value

 

and calculate( DISTINCTCOUNT(Table[DATE]), allselected(Table )) , will give you grand total

 

what final calculation you need

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Syndicate_Admin , A new column = DISTINCTCOUNT(Table[DATE])

will give grand total

in measure DISTINCTCOUNT(Table[DATE]) will give row value

 

and calculate( DISTINCTCOUNT(Table[DATE]), allselected(Table )) , will give you grand total

 

what final calculation you need

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

I need the value per row, so I tried the DISTINCTCOUNT(Table[DATE]) measure and it worked.

Thank you very much, @amitchandak !

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors