cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
jaweher89
Helper I
Helper I

Convert time spent to time

I have a column time-spent:

 

1H3M

4H7M

2M

 

I need to convert de time to be comptable in excel. 

For example 1H30M will be in total hours 1.5h

 

 

1 ACCEPTED SOLUTION
amitchandak
Super User IV
Super User IV

@jaweher89 , Try a new column

 

new column =
var _1 = SUBSTITUTE([column], "H", ".")
var _2 = SUBSTITUTE(_2, "M", "")
return
Quotient(_2*1,1) + (mod(_2,1)*10/6)



Did I answer your question? Mark my post as a solution! Appreciate your Kudos!!
Dashboard of My Blogs !! YouTube Channel !! Connect on Linkedin

Proud to be a Super User!

View solution in original post

2 REPLIES 2
amitchandak
Super User IV
Super User IV

@jaweher89 , Try a new column

 

new column =
var _1 = SUBSTITUTE([column], "H", ".")
var _2 = SUBSTITUTE(_2, "M", "")
return
Quotient(_2*1,1) + (mod(_2,1)*10/6)



Did I answer your question? Mark my post as a solution! Appreciate your Kudos!!
Dashboard of My Blogs !! YouTube Channel !! Connect on Linkedin

Proud to be a Super User!

View solution in original post

AilleryO
Continued Contributor
Continued Contributor

Hi,

 

Can you tell us exactly how is stored the time you want to convert.

Is it like you wrote 1h3m with the letters ? or more classic 01:03 ?

A screen copy of your data (not sensitive ones) might help us to help you 😉

Helpful resources

Announcements
PBI User Groups

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Get Ready for Power BI Dev Camp

Power BI Dev Camp - June 24th

Mark your calendars and join us for our next Power BI Dev Camp!

Top Solution Authors
Top Kudoed Authors