I’m looking for a solution regarding my phd research where i need to do some data wrangling, ie. transform my dataset into format suitable for graph/network analysis or to be more precise - make links from the existing nodes.
Anyways, I’ve built a workflow where I’m updating “EndOfExport” column - whenever “X” is found, today’s date is inserted. In the second step, i need to get the exact output like the one I’ve attached - and i need your help with it.
That means that i need to do row by row comparison in the loop until the end of the table. Each iteration should start form the next row and make comparison with the each row until the end of table (top-bottom).
Comparison is based on the CountryID and i’m comparing
1.) StartOfExport of CountryID in the row X with the StartOfExport
of CountryID in the row X+1 where i need to take out the larger date;
2.) EndOfExport of CountryID in the row X with the EndOfExport
of CountryID in the row X+1 where i need to take out the smaller date;
Please look at the Test - input - example.xlsx & Test - output - example.xlsx and you will get the general idea about the problem.
I’m working on a short notice so any advice/workflow would be very much appreciated!
I updated my workflow and added an alternative with a loop, so you can choose which one suits you the best without asking for the alternative and wait for my reply.