Results 1 to 2 of 2
  1. #1
    2 Star Lounger
    Join Date
    Mar 2006
    Posts
    195
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Syntax error in update statement (Access 2000)

    Could you help me find my syntax errror in the following statement

    Private Sub Command0_Click()
    Dim SQL As String
    SQL = "UPDATE TblClients.ClientID, TblClients.SetUp On TblClients SET TblClients.SetUp = 9"
    CurrentDb.Execute SQL
    End Sub

    I want to update the field SetUp in the table to read 9.

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Syntax error in update statement (Access 2000)

    Look up the syntax of the UPDATE statement in the SQL help. The general form is

    UPDATE tablename SET field1=value1, field2=value2

    or

    UPDATE tablename SET field1=value1, field2=value2 WHERE somecondition

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •