Oct 20, 2010 #1 primagic IS-IT--Management Jul 24, 2008 476 GB Getting Syntax Missing Operator error on the following line: Code: DoCmd.RunSQL "insert into dbo_OutcomeChanges (LeadID, OutcomeID, EmployeeID ) values (" & Me.LeadID & ", " & Me.OutcomeID.Column(1) & ", " & Forms!frmLeads!LoggedInAs & ");"
Getting Syntax Missing Operator error on the following line: Code: DoCmd.RunSQL "insert into dbo_OutcomeChanges (LeadID, OutcomeID, EmployeeID ) values (" & Me.LeadID & ", " & Me.OutcomeID.Column(1) & ", " & Forms!frmLeads!LoggedInAs & ");"
Oct 20, 2010 #2 MajP Technical User Aug 27, 2005 9,382 US best way to debug this is always do dim strSql as string strSql = "insert into dbutcomeChanges (LeadID, OutcomeID, EmployeeID ) values (" & Me.LeadID & ", " & Me.OutcomeID.Column(1) & ", " & Forms!frmLeads!LoggedInAs & ");" debug.print strSql 'now look at it. Post the results if necessary ... docmd.runsql strSql Upvote 0 Downvote
best way to debug this is always do dim strSql as string strSql = "insert into dbutcomeChanges (LeadID, OutcomeID, EmployeeID ) values (" & Me.LeadID & ", " & Me.OutcomeID.Column(1) & ", " & Forms!frmLeads!LoggedInAs & ");" debug.print strSql 'now look at it. Post the results if necessary ... docmd.runsql strSql