So I've had a good hunt around and I hope I'm posing a new problem here. I have a large amount of data where some records have a ParentID and other do not. What I need to do is find the Ultimate ParentID for every record, whether there are no hierarchical levels or 100+. E.g.
| ChildID | ParentID | UltimateID |
| A | | A |
| B | A | A |
| C | B | A |
| D | C | A |
| H | | H |
| L | | L |
| M | L | L |
| U | | U |
| V | U | U |
| W | V | U |
| X | W | U |
| Y | X | U |
| Z | Y | U |
Whilst I've been using Alteryx for over a year now, I've not needed to build my own macros yet and I think I've jumping in at the deep end with my attempts on this so any help would be gratefully received!