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
Anonymous
Not applicable

Counting number of row entries/calendar day and summarizing those values on a calculated table

Hi there,

 

I'm really new to using Power BI and I was hoping you could give me some quick help on a question. I work for a factory and I'm creating a dashboard for stops. I have multiple rows of stops with dates associated with them but I want to be able to count the # of stops entries/day. I have a column with the date & time and a column with the reason for the stop. I was thinking I should create a calculated table to summarize information by day like this one, given that for 1 day I might have 50 entries for stops, but I want to be able to have a quick summary that is linked to the stops entries raw data to summarize how many stops they had for example for July 2nd 2019. I'm trying to count the # of entries in my raw data/calendar day without using a visual since I need to get these numbers to then create a measure and use that measure for visuals.

 

I'd really appreciate any help you can provide!

 

Thanks,

1 ACCEPTED SOLUTION

@Anonymous you can still achieve all this, you don't need seperate table or something like this. DAX is very powerful language



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

@parry2k ,

 

I still don't understand how to complete those 3 for the calculation in the formula below at once. Could you explain?

 

Thanks,

parry2k
Super User
Super User

@Anonymous you don't need to create seperate summarize table, just add a measure and whatever granularity you will pick , it wil work.

 

ALthough the best practice is to add Date table in your model whihc will allows to have better control for time intelligence, there are many posts on how to add date table in your model.

 

the simple measure you need for this is

 

# of Stops = COUNTROWS( YourTable )

Now when you drop a date and/or reason of stop, alongwith above measure, you will get count of stops.



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Anonymous
Not applicable

Hi @parry2k ,

The only reason why I didnt want to have it as a measure is because I'll be using this stops/day as part of another formula. Basically I need to do this 3 times:

 

1. to find stops/calendar day for each production line

2. to sum all minutes the line was running/calendar day

3. to sum all minutes the line was not running/calendar day

 

And finally use this formula:

 

Stops/schedule time = stops per day/(uptime per day - downtime per day)*1440

 

Thats why I figured I had to get a new table which would have items 1-3 and then on the 4th column add this stops/schedule time as a measure

@Anonymous you can still achieve all this, you don't need seperate table or something like this. DAX is very powerful language



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

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.