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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Shivrajvk
Regular Visitor

Duration in Power Bi

I have a column named duration in which data is in the format hh:mm: ss 

The data is displayed correctly in Excel but when I import the excel file in Power Bi, the format of the column changes to a date/time format, something like 12/31/1899 HH:MM: SS. 

How do I get my data in the HH:MM:SS format in Power Bi? I need to calculate the average of that column. 

Please help.

 

Note: I've tried changing the column in excel to General format and then changing the format to duration in Power BI, that gives me the format as DD:HH:MM:SS. 

 

@Greg_Deckler can you please help me?

 

4 REPLIES 4
Shivrajvk
Regular Visitor

Hi @AbbasG , I have the data as below in in Excel, 

Shivrajvk_0-1668598959782.png

 

And what I have in Power Bi is like 

 

Shivrajvk_1-1668599001190.png

I want the data in the format HH:MM:SS. 

 

@Shivrajvk I think you can use the FORMAT function here.

AbbasG_0-1668610372652.png

Additionally, you can also refer the following solution - https://community.powerbi.com/t5/Desktop/Extracting-only-minutes-and-seconds-from-a-date/m-p/2201488...

Hope it helps!

@AbbasG The Format function works by the output is in a text format. I want to calculate the average of the entire duration column. Is there any way to do that?

 

AbbasG
Memorable Member
Memorable Member

@Shivrajvk please share some sample data (after removing all the sensitive information), with desired out come.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.