OleDbException: Syntax error in UPDATE statement

V

VB Programmer

I get this error when running an UPDATE command against my db. (I paste the
SQL in Access and it works fine!)

System.Data.OleDb.OleDbException: Syntax error in UPDATE statement. at
System.Data.OleDb.OleDbCommand.ExecuteCommandTextErrorHandling(Int32 hr) at
System.Data.OleDb.OleDbCommand.ExecuteCommandTextForSingleResult(tagDBPARAMS
dbParams, Object& executeResult) at
System.Data.OleDb.OleDbCommand.ExecuteCommandText(Object& executeResult) at
System.Data.OleDb.OleDbCommand.ExecuteCommand(CommandBehavior behavior,
Object& executeResult) at
System.Data.OleDb.OleDbCommand.ExecuteReaderInternal(CommandBehavior
behavior, String method) at System.Data.OleDb.OleDbCommand.ExecuteNonQuery()
at ExecuCare.AdminSubscriberManagement.cmdSave_Click(Object sender,
EventArgs e) in
c:\inetpub\wwwroot\EC\Secured\AdminCustomerManagement.aspx.vb:line 339

Here's the SQL:
UPDATE Customers SET FirstName = 'Robert', LastName = 'Smith', Address = '',
BusinessPhone = '', CellPhone = '', City = '', FaxPhone = '', HomePhone =
'', Notes = '', Password = 'ecadmin', State = '', UserName = 'admin', Zip =
'', IsAdmin = True WHERE CustomerId = 1;

Any ideas?
Thanks.
 

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

Top