In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests after December 31, 2025. Set up your security questions now so you can recover your account anytime, just log out and back in to get started. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

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

Duration Accross 2 day

JTCairns
8 - Asteroid

Hi All

 

My brain wont work today, im calcuating duration of certain shifts but i cant remeber how to take into account shifts over 2 days. e.g

 

Arrive           Leave
21:00:00      07:00:00

 

This should be 10 not 14. Anyone got a work around

 

Cheers

2 REPLIES 2
BenMoss
ACE Emeritus
ACE Emeritus

Create two calculated fields.

 

 

ArriveNew

 

"2018-01-01 "+[Arrive]

 

LeaveNew

 

if [Leave] > [Arrive] 

then "2018-01-01 "+[Leave]

else "2018-01-02 "+[Arrive]

endif

 

Then do your datediff on these new fields.

 

Ben

JTCairns
8 - Asteroid

Magic!! Cheers @BenMoss

Labels
Top Solution Authors