Forum Discussion
BigPatJennings
3 years agoFrequent Visitor
M Language - convert duration to seconds
Apologies, but I really don't know M at all and I've run into difficulties with time and duration. I have a table with, amongst other things, 15 columns of durations in the format xx:xx:xx . I curren...
- 3 years ago
If you look on the right hand side of this web page, you'll see a 'Recommendations' panel and they might help you.
Alternatively, if you get the column into a duration data type, you can use function:
https://learn.microsoft.com/en-us/powerquery-m/duration-totalseconds
ronrsnfld
3 years agoSuper User
You can either add a column or transform the existing column.
- Ensure your dataColumn is type as a duration
- To add a column, navigate to the Add Custom Column item and, for a formula:
=Duration.TotalSeconds([dataColumn])