Hi experts!
I'm trying to traverse and convert a Parent|Child file into a separate hierarchy, with a header.
The 'depth' of the Parent|Child relationships is yet unknown, so the output could stretch to many columns on the right.
I have tried coding for just two input columns, with little success as it's very slow and restrictive.
Any help would be much appreciated. Thank you.
Input tab:
Output Tab:
I'm trying to traverse and convert a Parent|Child file into a separate hierarchy, with a header.
The 'depth' of the Parent|Child relationships is yet unknown, so the output could stretch to many columns on the right.
I have tried coding for just two input columns, with little success as it's very slow and restrictive.
Any help would be much appreciated. Thank you.
Input tab:
Parent | Child | Description |
Europe | UK | United Kingdom |
Europe | FR | France |
Europe | ES | Spain |
Europe | IT | Italy |
Europe | DE | Germany |
UK | LDN | London |
UK | LDS | Leeds |
UK | LIV | Liverpool |
FR | PAR | Paris |
FR | LYN | Lyon |
FR | DIJ | Dijon |
FR | CAL | Calais |
ES | MAD | Madrid |
ES | MAL | Malaga |
ES | VAL | Valencia |
LDN | RCH | Richmond |
LDN | CHW | Chiswick |
MAD | SAL | Salamanca |
MAD | RET | Retiro |
Output Tab:
Continent | Country | Country Desc | City | City Desc | Town | Town Desc |
Europe | ||||||
UK | United Kingdom | |||||
LDN | London | |||||
RCH | Richmond | |||||
CHW | Chiswick | |||||
LDS | Leeds | |||||
LIV | Liverpool | |||||
FR | France | |||||
PAR | Paris | |||||
LYN | Lyon | |||||
DIJ | Dijon | |||||
CAL | Calais | |||||
ES | Spain | |||||
MAD | Madrid | |||||
SAL | Salamanca | |||||
RET | Retiro | |||||
MAL | Malaga | |||||
VAL | Valencia |