I'm working on a project where I need to take a record set containing a unique record ID and a dollar amount (positive/negative) and see if its inverse amount is contained within the remaining record set. I need it to return all matches as these matches will be used for further testing down stream when combined with additional data.
So I created an iterative macro that takes a record set and takes the first record and finds any matches and outputs itself and the matches, and the record set minus the record tested is sent back around again.
This seems to be working, BUT, it isn't returning all the results I'm expecting to see. I have traced the data types through the process and they seem correct. I added browses to everything and watched the data flow through and it looks good. So I'm at a loss as to what I'm missing.
In the attached example it is not returning 3 matches. I have included the driving workflow, matching macro, and data file with example data and expected results.
My questions are:
1. What am I missing that is not allowing these records to be matched and returned.
2. The macro in my mind seems to have to many process steps, but I can't think of a different way of doing it. Is there a better/shorter method?
3. Is it possible to get the same results NOT using a macro.
Thanks for the help!
-Winston
Solved! Go to Solution.
Thanks for the code, it works as expected!. I knew there had to be a better way. I will still be using a regular macro as this code will be reused multiple times in the overall project.