Tyring to create a SQL statement to update a data row

Trying to do an update statement in VBA

strSQL = "UPDATE [Termination] SET [Division] ='" & Division & "' WHERE [Emp ID] = '" & EmpID & "' AND [Key ID] = '" & KeyID & "'"

The above creates this

"UPDATE [Termination] SET [Division] ='24' WHERE [Emp ID] = 'JD50' AND [Key ID] = '1010264890'"

When is runs I get

Runtime error 3061 – too few parameters. Expected 1.

Help appreciated.

Thanks!

Related Posts