Hi, I am new to Alteryx and wondering if anyone could kindly help with my problem.
I receive data in a format where most entries are in order or simply need swapping around so that row AA, or CA is before row BB.
For these entries, they must be in the matching pairs with a blank row before the next pair.
The amounts must also match; sometimes multiple BB's add up to one AA/CA in which case I break them up as shown in my example.
I am trying to use Alteryx to do the following:
1) Swap entries that are not in order around so that row AA, or CA is before row BB
2) Insert a blank row between each pair
3) Match all entries, even in the situation where multiple unmatched BB entries add up to one AA or CA entry
In the case of unmatched entries, I must count the amount of unmatched BB entries to identify which unmatched AA or CA entries they correspond with. I will then insert these as shown in bold, changing the amount of the first entry so that it matches the second, this does not change the total sum of amount.
There can often be many of these unmatched entries so I am currently using trial and error when adding unmatched BB entries to find their corresponding match.
I understand there are a few challenges here, I have been trying to use Alteryx but as a new user have had no luck. If anyone can assist that would be greatly appreciated!
Example:
Some AA's or CA's can be made up of two BB's as shown in bold | |||||||||
What I have | What I need | ||||||||
Side | Ref 1 | Amount | Ref 2 | Side | Ref 1 | Amount | Ref 2 | ||
AA | SXC | 777 | SWW | AA | SXC | 777 | SWW | ||
BB | SXD | 777 | SWE | BB | SXD | 777 | SWE | ||
BB | EAA | 777 | CFE | ||||||
AA | EAD | 777 | CWD | AA | EAD | 777 | CWD | ||
AA | DER | 477 | GEW | BB | EAA | 777 | CFE | ||
BB | FAU | 122 | GER | ||||||
BB | BWE | 355 | GRE | CA | XEW | 9794 | DCW | ||
CA | XEW | 9794 | DCW | BB | SEE | 9794 | DCW | ||
BB | SEE | 9794 | DCW | ||||||
AA | DER | 122 | GEW | ||||||
BB | FAU | 122 | GER | ||||||
AA | DER | 355 | GEW | ||||||
BB | BWE | 355 | GRE |