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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
sunah132
Helper I
Helper I

count rows as subtotal

Hi, I'm building a report that would have count rows as subtotal, not the actual sum of the values during the date period. From current view to count distinct row view, how can I manipulate to have this view?

Thank you in advance!

Current View   
ID17-Jun18-Jun19-JunTotal order
1234565106
     
     
Count row view   
ID17-Jun18-Jun19-JunOrdered days
1234565102
1 ACCEPTED SOLUTION
bhanu_gautam
Super User
Super User

@sunah132 , You need to create a measure that calculates the number of days with orders for each id

 

OrderedDays =
CALCULATE(
COUNTROWS(
FILTER(
SUMMARIZE(
TableName,
TableName[ID],
TableName[DateColumn],
"OrderCount", SUM(TableName[OrderCount])
),
[OrderCount] > 0
)
)
)

 

I have attached PBIX with your sample data




Did I answer your question? Mark my post as a solution! And Kudos are appreciated

Proud to be a Super User!




LinkedIn






View solution in original post

2 REPLIES 2
bhanu_gautam
Super User
Super User

@sunah132 , You need to create a measure that calculates the number of days with orders for each id

 

OrderedDays =
CALCULATE(
COUNTROWS(
FILTER(
SUMMARIZE(
TableName,
TableName[ID],
TableName[DateColumn],
"OrderCount", SUM(TableName[OrderCount])
),
[OrderCount] > 0
)
)
)

 

I have attached PBIX with your sample data




Did I answer your question? Mark my post as a solution! And Kudos are appreciated

Proud to be a Super User!




LinkedIn






Thank you! It helped exactly how I was tried to solve. 🙂

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Top Solution Authors