Alteryx Designer

Find answers, ask questions, and share expertise about Alteryx Designer.

Change Minutes to Hours, Minutes

Highlighted
8 - Asteroid

We have employees tracking some work they are currently working on.  Right now, we have them calculating time spent in minutes.  They are tracking this in SharePoint, which is saving the data as a number.

 

Management wants an accumlated total of hours/minutes spent on these projects. This information will be growing daily.

 

Any way to show the ongoing total as HH:MM?

Highlighted
16 - Nebula
16 - Nebula

A formula like:

PadLeft(ToString(Floor(TotalMinutes/60), 0), 2, '0') +
":" + PadLeft(ToString(Mod(TotalMinutes, 60), 0), 2, '0')

Should give you what you want.

 

 

 

 

Highlighted
Alteryx Certified Partner
Alteryx Certified Partner

Screen Shot 2016-06-06 at 10.50.07 AM.png

 

I just saw that @jdunkerley79 answered too.  I can't wait to see his solution too.

Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and reboot. Order shall return.
Highlighted
5 - Atom

Thanks MarqueeCrew !

I re-used it.

 

I simply modified the last calculation (Time) to avoid having results like 5:7 when you probably expect 5:07

My code:

 

If length([Minutes])>1
THEN tostring([Hours],0,1)+":"+ToString([Minutes])
ELSE tostring([Hours],0,1)+":0"+ToString([Minutes])
ENDIF

Hope it will help.

Highlighted
5 - Atom

This is just that I need! You are the best. Thank you.

Labels