Get Inspire insights from former attendees in our AMA discussion thread on Inspire Buzz. ACEs and other community members are on call all week to answer!

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

How to find difference between time in seconds

AshokBhatt
7 - Meteor

Hi,

I tried to find difference between time in seconds but unable to. Could you please suggest what should be the best way to find difference.

I was using DateTimeDiff() function.

 

Regards,

18 REPLIES 18
KoryC
Alteryx Alumni (Retired)

Hey Chris - we'll have that patched up in a future release!

JordanB
Alteryx
Alteryx

For Alteryx to perform any datetime function the accepted format needs to be YYYY-mm-dd HH-mm-ss. You will therefore need to append a placeholder date to the front of the HH-mm-ss you currently have in your data. I tested this and it gives you the results in seconds once the placeholder date has been added. 

 

Just reach out if you have any other questions.

 

chris_love
12 - Quasar

Thanks Jordan - yes thanks we solved, this was a cross-post of this thread. http://community.alteryx.com/t5/Data-Preparation-Blending/How-to-find-difference-between-time-in-sec...

colleen_s_fresh
5 - Atom

Is there a way you could show your statement that you used in the workflow for the date difference?  I can't open your workbook because its a newer version and it will probablly take IT days to upgrade my version.

 

Much appreciated!

AshokBhatt
7 - Meteor

Sure.

PFA screenshot of workflow and workflow in previous version too. Trust this helps.

TimeDiff.png

 

AshokBhatt
7 - Meteor

TimeDiff.png

colleen_s_fresh
5 - Atom

Thanks for responding.  I realized the issue I was having is that I had coded "d" for days like you do in Excel and Alteryx requires "days".

nicks10
6 - Meteoroid

Great thanks for that. If a less convoluted solution emerges, please do advise!

vartika31
6 - Meteoroid

What if we want to get the difference in hh:mm:ss format (instead of only hours or minutes or seconds? How do we get that?

Labels