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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
ranis1227
Helper I
Helper I

Time value for an Average Column

Hello,

 

I created a summarized table and  am trying to convert an average time value (Average Hour Time in this case) to a time format (HH:MM:SS). See Screenshot: 

 

ranis1227_0-1667937526110.png

 

So 12.11 for Medicine Emory A should convert to roughly 12:07. 

 

Any help will be greatly appreciated.    

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

Hi @ranis1227 ,

 

You can try this method:

 

New a measure:

Average_Time =

var _hours = ROUNDDOWN(SUM('Table'[Average Hour Time]), 0)

var _minutes = (SUM('Table'[Average Hour Time]) - _hours) * 60

var _seconds = (_minutes - ROUNDDOWN(_minutes, 0)) * 60

return

TIME(_hours, _minutes, _seconds)

 

 

Need to change the type here:

vyinliwmsft_0-1667971215607.png

 

The result is:

vyinliwmsft_1-1667971215611.png

 

 

Hope this helps you. Here is my PBIX file.

 

Best Regards,

Community Support Team _Yinliw

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-yinliw-msft
Community Support
Community Support

Hi @ranis1227 ,

 

You can try this method:

 

New a measure:

Average_Time =

var _hours = ROUNDDOWN(SUM('Table'[Average Hour Time]), 0)

var _minutes = (SUM('Table'[Average Hour Time]) - _hours) * 60

var _seconds = (_minutes - ROUNDDOWN(_minutes, 0)) * 60

return

TIME(_hours, _minutes, _seconds)

 

 

Need to change the type here:

vyinliwmsft_0-1667971215607.png

 

The result is:

vyinliwmsft_1-1667971215611.png

 

 

Hope this helps you. Here is my PBIX file.

 

Best Regards,

Community Support Team _Yinliw

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

Thank you @v-yinliw-msft . This is exactly what I needed.  

VahidDM
Super User
Super User

Hi @ranis1227 

 

Check out the below links and you will find how to convert your number to time:
https://community.powerbi.com/t5/Desktop/Convert-Decimal-Duration-in-HH-MM-SS-format/m-p/959061
https://community.powerbi.com/t5/Power-Query/How-to-convert-decimal-time-to-hh-mm-and-summarize-that...

https://www.myonlinetraininghub.com/converting-decimal-time-to-days-hours-minutes-in-power-bi

 

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.

Appreciate your Kudos!! 

Badges.jpg

LinkedIn | Twitter | Blog | YouTube 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 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.