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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
JeffersonMichJ
Regular Visitor

How to show the remaining time in a stacked bar column

I have a dataset containing the beginning and the end of a series of tasks that equipment executes. In this table, there is the name of the equipment, the task, beginning datetime, and end datetime.

 

I need to create a bar chart where each segment represents the total amount of minutes for a specific task for each equipment. However, I also need to insertthe free time into the chart.

 

Considering the following example

EquipmentTaskStartFinish
Car 1Deposit12/5/2023 10:00:0012/5/2023 11:00:00
Car 1Withdraw12/5/2023 12:00:0012/5/2023 13:00:00
Car 1Deposit12/5/2023 13:00:0012/5/2023 14:00:00
Car 1Withdraw12/5/2023 14:00:0012/5/2023 15:00:00
Car 1Deposit
12/5/2023 18:00:00
12/5/2023 19:00:00

 

Car 1 spent 3 hours depositing and 2 hours withdrawing, with a total free time on 12/05/2023 of 19 hours.

The bar chart would look something like this if the date filter was applied on 12/07/2023:

JeffersonMichJ_0-1701785787168.png

How can I do this within Power BI? Currently, I am creating fictitious "Free Time" tasks outside of Power BI for each equipment.

1 ACCEPTED SOLUTION
Fowmy
Super User
Super User

@JeffersonMichJ 

I created three measures and visualized using the 100% Stack Bar Chart. The time difference was calculated as minutes.

Here are is the result and the file is attached below:

Fowmy_0-1701803677955.png

 



Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

2 REPLIES 2
Fowmy
Super User
Super User

@JeffersonMichJ 

I created three measures and visualized using the 100% Stack Bar Chart. The time difference was calculated as minutes.

Here are is the result and the file is attached below:

Fowmy_0-1701803677955.png

 



Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Thank you. That's exactly it. With this, I can also filter the first and last Start column and multiply the free time if more days are selected! Thanks.

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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