Hi Mike,
Maybe I am over simplifying things, but this how I understand your problem:
- Three tables
- These tables doesn't have associations with each other (parent - child, like car - car parts). Is that correct? (Although I think it's otherwise)?
- Different attributes of the three tables are copied in a new master table
If all 3 tables have the same amount of rows: Loop through Table 1 and:
- Create Table4 object en Table4 list
- Fill Attributes Table1 to Table4 object
- Add Table4 object to a list of Table4
Then Loop through Table 2 and
- Loop through List of Table4
- Fill Table4 object with Table2 attributes (change)
Then Loop through Table 3 and
- Loop through List of Table4
- Fill Table4 object with Table3 attributes (change)
When there are parent-child relations between the tables you create a loop within a loop withing a loop. Result will be a Table4 that looks like an "Excel sheet" which contains columns with duplicate data.
Hope that helps