SQL Syntax Error

  • Thread starter auujxa2 via AccessMonster.com
  • Start date
A

auujxa2 via AccessMonster.com

I'm getting syntax error on the last 2 parts of the select statement.
everything was fine until Me.cboNewVendor (which is a number field. the last
2 are text)

strSQL = "INSERT INTO [MasterTbl] ([Store #], Location, Stores, Department,
[Vendor Number], Brand, Lifestyle)" & _
" SELECT Store, Description, Stores,""" & Me.cboNewSimDept & """," & Me.
cboNewVendor & ",""" & Me.cboBrand & """," & "" & Me.cboLifestyle & """ & _

FROM [StoreTbl]"
 
M

Michel Walsh

strSQL = "INSERT INTO [MasterTbl] ([Store #], Location, Stores, Department,
[Vendor Number], Brand, Lifestyle)" & _
" SELECT Store, Description, Stores,""" & Me.cboNewSimDept & """," & Me.
cboNewVendor & ",""" & Me.cboBrand & """,""" & Me.cboLifestyle & """
FROM [StoreTbl]"


(with line continuation, as required)



Vanderghast, Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top