cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
diskovered Member
Member

How to convert mm:ss to seconds (duration)

How do I convert this to seconds either via measure or m. Help is much appreciated. Thanks

 

convert.PNG

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
mwegener Member
Member

Re: How to convert mm:ss to seconds (duration)

Hi @diskovered

 

format the column with Power Query (M) as duration.

With Duration.TotalSeconds([Column]), you get the seconds.

 

Duration.png

View solution in original post

4 REPLIES 4
Highlighted
mwegener Member
Member

Re: How to convert mm:ss to seconds (duration)

Hi @diskovered

 

format the column with Power Query (M) as duration.

With Duration.TotalSeconds([Column]), you get the seconds.

 

Duration.png

View solution in original post

diskovered Member
Member

Re: How to convert mm:ss to seconds (duration)

Thanks. 

 

Got mine to work = Table.TransformColumns(#"Changed Type",{{"Value - Copy", Duration.TotalSeconds, type number}})

BIdevelopement New Member
New Member

Re: How to convert mm:ss to seconds (duration)

Could you please explain this in more detail?

 

I have durations in my data set that are, for example, 7 minutes 17 seconds, but powerBI auto formats the duration to be 7 hours 17 minutes 0 seconds. How can I change this?

 

mwegener Member
Member

Re: How to convert mm:ss to seconds (duration)

What is your source?

Is there a "Changed Type" step?

Maybe you could insert a "Add Prefix" step before the "Changed Type" step and change the value to this format "00:07:17".

 

Helpful resources

Announcements
Can You Solve These Challenge

Challenge: Can You Solve These?

Find out how to participate in the first Power BI 'Can You Solve These?' challenge.

Community News & Announcements

Community News & Announcements

Get your latest community news and announcements.

Virtual Launch Event

Microsoft Business Applications October Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

Community Kudopalooza

Win Power BI Swag with Community Kudopalooza!

Each week, complete activities and be qualified in the drawing for cool Power BI Swag.

Users Online
Currently online: 121 members 1,496 guests
Please welcome our newest community members: