I'm trying to figure out the solution for what I'm sure is a very simple problem but my brain isn't cooperating at the moment.
I have 2 input files with account numbers and balances. The first one is the Master file, the second one is from a different source. I want to match up the accounts using the following logic:
1)Everything in the Master file transfers over to the final output
2)Rows that are in TestInputB and match to rows in Master (by account number) get added to final output, but the Balance amount from TestInputB is moved to Balance2 column
3)Rows that are in TestInputB but don't exist in the Master, are added to the output and Balance is mapped to Balance2
So far I've got it to where the original records and the unmatched records get added to the output, but I'm a bit stumped on how to get the matching records and move the balance over to column 2. Do I need to do another union? or am I overcomplicated a simple problem?
Solved! Go to Solution.
User | Count |
---|---|
19 | |
15 | |
13 | |
9 | |
8 |