I am trying to think through the best way to approach this in FME. I need to create polylines from a CSV file. I have two files in the following format:
Â
File1 contains one row per line, including the start and end coordinates for all lines:
Line123, StartX, StartY, EndX, EndY
Line456, StartX, StartY, EndX, EndY
Â
File2 may or may not have additional midpoints. Each midpoint is on a new row. So two midpoints for Line123 would look like:
Â
Line123, X1, Y1
Line123, X2, Y2
Â
I need to combine these in the correct order to rebuild the line. For each unique LineID, I need eStartXY] + Midpoints] + ]EndXY], and the midpoints need to be in the same order as originally presented.
Â
There are likely many ways to approach this. Here is my first attempt. I know I can use LineBuilder to construct any midpoints from the second file. It's set to wait for all inputs and process at the end, grouping by LineID. I know the order of vertices depends on the input.
Â
Â
Â
I want the LineBuilder to process the span START, then the midpoints, then the END. I bring the start and end into the LineBuilder. But now I'm realizing I don't have control over execution order. I can't guarantee I'll get points in the order I want. Now I'm trying to brainstorm and think about how to restructure...