Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

How create the change turn with alteryx ?

Andrea92
7 - Meteor

Hi all, 

 

I've created manually with excel a simulation of change turn. In the table TK indicate the 
change of means of transport. How can I replicate the same view with Alteryx please?

Note that the part underlined doesn't exist, but that's what I want to get. 

 

Is there someone that can help me please ? 

 

Thanks a lot.

 

Andrea

8 REPLIES 8
Andrea92
7 - Meteor

Any suggestion please ?

Jonathan-Sherman
15 - Aurora
15 - Aurora

Hi @Andrea92,

 

Which columns are you trying to recreate? And what would be an example of one of the identifiers?

 

Regards,

Jonathan

Andrea92
7 - Meteor

From TK1 to TK9. For the first means of transport ( TK1) you have three rotation in 27/October.  The first rotation is at 00.05The second rotation of TK1 is possible when the means of transport come back to destination, so in this case at 11:35. Indeed you cant' use it before 10:20 and finally there is the last rotation. 

TonyA
Alteryx Alumni (Retired)

I think I understand. You are scheduling some kind of transportation. Transport 1 leaves station A at 12:05AM, travels to T and returns at 10:20. It is then available for the next run which leaves at 11:35. In the meantime six other vehicles leave on other runs. I built the attached workflow that calculates this using an iterative macro but I'm getting slightly different results. You have vehicle 2 leaving on a run at Row 8 that returns at 14:40, but you have it going out again at 12:30. If I understand the problem correctly, it is leaving on another run before it has returned. Please let me know if I'm missing something.

 

EDIT: By the way, if you want to allow for loading/unloading time between runs, you can change "0" in the first Multi-Row Formula tool in the macro to a number that represents the number of minutes for the layover. For example,

IF IsNull([Row-1:LatestArrival]) OR DateTimeDiff([Dept Time],[Row-1:LatestArrival],"minutes") > 20
THEN [Arvl Time2]
ELSE [Row-1:LatestArrival]
ENDIF

would allow for a 20 minute layover before the next run.

Andrea92
7 - Meteor

Thanks a lot for your support Tony. It's very helpful.

 

Please could you let me know there is a limit with the input macro because I have a file with 2096 row and the input macro text support max 1000 cell.

 

Andrea 

 

Andrea92
7 - Meteor

Capture1.PNG

TonyA
Alteryx Alumni (Retired)

Interesting. I just built a data set with 2600 rows and it ran with no problem. I've attached a slightly modified workflow (to fix a sort order problem) and included the larger data set. How many transports do you have?

Andrea92
7 - Meteor

Done. Thanks a lot. 

Labels