Why would source structure change? Are the field names consistent, just not always included? If the names are the same as in the master, open recordset objects and loop through source fields and save to corresponding field in master. Example:
Code:
Dim rsDataSource As ADODB.Recordset
Dim rsDataDest As ADODB.Recordset
Dim j As Integer
Set rsDataSource = New ADODB.Recordset
Set rsDataDest = New ADODB.Recordset
rsDataSource.Open "SELECT * FROM [source table];", CurrentProject.Connection, adOpenStatic, adLockPessimistic
rsDataDest.Open "SELECT * FROM [dest table] WHERE 0=1;", CurrentProject.Connection, adOpenDynamic, adLockOptimistic
Do While Not rsDataSource.EOF
rsDataDest.AddNew
For j = 0 To rsDataSource.Fields.Count - 1
rsDataDest.Fields(rsDataSource.Fields(j).Name) = rsDataSource.Fields(j)
Next j
rsDataDest.Update
rsDataSource.MoveNext
Loop
If corresponding fields do not have same name, then need a 'map' table that associates field names. Code would do a lookup to the 'map' table to retrieve the corresponding master field name.
strDestField = DLookup("DestField", "Map", "SourceField='" & rsDataSource.Fields(j).Name & "'")
rsDataDest.Fields("[" & strDestField & "]") = rsDataSource.Fields(j)