G
Guest
of an SQL statement"
Hello, I cannot figure out what is wrong with the code below. I keep getting the above runtime error. But it runs no problem in Desiqn Query mode, once I've set the primary keys for the two tables. Any idea what the problem is?
Dim strSQL As String
strSQL = "SELECT zmax2.*, rooting2.* " & _
"FROM zmax2 LEFT JOIN rooting2 " & _
"ON zmax2.musym = rooting2.musym"
'Turn off warning message.
DoCmd.SetWarnings False
DoCmd.RunSQL strSQL
'Re-enable warning message
DoCmd.SetWarnings True
RichardA
Hello, I cannot figure out what is wrong with the code below. I keep getting the above runtime error. But it runs no problem in Desiqn Query mode, once I've set the primary keys for the two tables. Any idea what the problem is?
Dim strSQL As String
strSQL = "SELECT zmax2.*, rooting2.* " & _
"FROM zmax2 LEFT JOIN rooting2 " & _
"ON zmax2.musym = rooting2.musym"
'Turn off warning message.
DoCmd.SetWarnings False
DoCmd.RunSQL strSQL
'Re-enable warning message
DoCmd.SetWarnings True
RichardA