Hi,
I am working on creating Parent-Child flow in Alteryx. In the Input, the "Quantity" can be under Child. But I need the "Quantity" to be under "Base child/First child(child without -)".
There are two special cases here,
1. There could be as many Children under each Parent
2. There could be no Base child/First child (child without -)
Please see example Input and Output images
Any help is appreciated!. Many Thanks!
Solved! Go to Solution.
Hello @Meoth
I'm sure that there are several ways how to do it, one of them will be using Summarize tool.
Add a record ID . Group the data on Parent and then Sum up Quantity, First Act, First Child, First RecordID now you will have the parent with Quantity.
Just ensure that the naming of the fields are the same, so delete Sum, First etc..
Join the output of the Summarize Tool with the original data, Using the RecordID, in the joint tool remove all the items that comes from the Right. Connect R output to a Formula tool and set 0 for Quantity. Now union J and R. Add a Sort Tool and you will have the output that you need.
@OTrieger , Thank you so much for your timely help. It worked!
😎