When I run the query, I got runtime error 3075 syntax error(missing operator) in query expression. Is there something wrong with the query below?
I have stared it for 30 mins and I still cant find what is wrong with it. The VALUES() should be in a line but in this thread it wont fit so I divide it into two lines. Any help will much appreciated. Thanks!
Code:
StrSQL1 = "INSERT INTO tmpPartsTableAll ([TmpPartNumber], [TmpUnitID], [TmpPartDescription], [TmpMaterial], " & _
"[TmpQty], [TmpPartCost], [TmpVendorPart], [TmpVendorID], [TmpVendorDesc], [TmpComments])" & _
"VALUES ( " & StrPartNumber & "," & StrUnitID & ", " & StrPartDescription & ", " & StrMaterial & ", " & StrQty & ", " & StrPartCost & ", " & StrVendorPart & ", " & StrVendorID & ", " & StrVendorDesc & ", " & StrComments & ")"
docmd.setwarnings False
docmd.runSQL StrSQL1
docmd.setwarnings True
I have stared it for 30 mins and I still cant find what is wrong with it. The VALUES() should be in a line but in this thread it wont fit so I divide it into two lines. Any help will much appreciated. Thanks!