I have the following code that copies tables and i need to add a string on the new table that will be copied. ANy suggestions
Set RsSOBP = CurrentDb.OpenRecordset("SELECT SOBP FROM RFG_Append;")
strtable = " RsSOBP!SOBP "
RFG = "RFG"
'create RFG tables
Do While Not RsSOBP.EOF
DoCmd.SetWarnings (False)
strsqlb = "SELECT Generic.* INTO & strtable &'RFG' FROM Generic;"
DoCmd.RunSQL strsqlb
DoCmd.SetWarnings (True)
RsSOBP.MoveNext
Loop
My generic tables are created with the following code... that works fine....
'create generic tables
Do While Not RsSOBP.EOF
DoCmd.SetWarnings (False)
strsqla = "SELECT Generic.* INTO " & RsSOBP!SOBP & " from Generic;"
DoCmd.RunSQL strsqla
DoCmd.SetWarnings (True)
RsSOBP.MoveNext
Loop
thanks guys in advance..
Set RsSOBP = CurrentDb.OpenRecordset("SELECT SOBP FROM RFG_Append;")
strtable = " RsSOBP!SOBP "
RFG = "RFG"
'create RFG tables
Do While Not RsSOBP.EOF
DoCmd.SetWarnings (False)
strsqlb = "SELECT Generic.* INTO & strtable &'RFG' FROM Generic;"
DoCmd.RunSQL strsqlb
DoCmd.SetWarnings (True)
RsSOBP.MoveNext
Loop
My generic tables are created with the following code... that works fine....
'create generic tables
Do While Not RsSOBP.EOF
DoCmd.SetWarnings (False)
strsqla = "SELECT Generic.* INTO " & RsSOBP!SOBP & " from Generic;"
DoCmd.RunSQL strsqla
DoCmd.SetWarnings (True)
RsSOBP.MoveNext
Loop
thanks guys in advance..