Ok, I think I've found some basic code I can modify to do what I am looking for. This is what I'm working from:
Public Sub CreateExportQuery()
Dim CriteriaID As String
Dim Record As String
Dim Sample As Recordset
Dim Test As String
CriteriaID = ""
Record = "SELECT * FROM tbl_Innovient_Input_Fields;"
'Set Sample = CurrentDb.OpenRecordset(Record, dbOpenDynaset)
'For a = 1 To Sample.RecordCount
' Test = Sample!Source_Field_Name
'Next a
Test = "SELECT * FROM"
Set Sample = CurrentDb.OpenRecordset("tbl_Innovient_Input_Fields", dbOpenTable)
For a = 1 To Sample.RecordCount
Test = Test & " " & Sample!Source_Table_Name & "!" & Sample!Source_Field_Name
Sample.MoveNext
Next a
Debug.Print Test
End Sub
I have already done some modifying which might explain why some of the variables are unused.
I would still like to know anyone's input as to whether this is a smart way to set up this db.
Thanks!
Bookmarks