error when executing sql update statement

Results 1 to 2 of 2

Thread: error when executing sql update statement

  1. #1
    Wendi Sisson Guest

    Default error when executing sql update statement

    My ASP code contains these lines:<BR><BR>update_def = "UPDATE TermDefinitions SET Definition = " & chr(34) & new_def & chr(34) & " WHERE Term = &#039" & search_term & "&#039" <BR>Set rs = conn.Execute(update_def)<BR><BR>And I get this error:<BR>Microsoft OLE DB Provider for ODBC Drivers error &#039 80040e10&#039 <BR>[Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 1. <BR>/simpl/thesaurus_editing.asp, line 402 <BR><BR>The actual sql generated looks like this example:<BR>UPDATE TermDefinitions SET Definition = "This is the new definition" WHERE Term = &#039Build&#039 <BR><BR>I have determined that the problem is in the Execute line. Do you have any idea what it is? This is my first time to use an update statement. I also get the same error when I try to add a record to my Access database using the insert method. Thanks, Wendi

  2. #2
    Join Date
    Dec 1969

    Default RE: error when executing sql update statement

    hi, think it should be correct.<BR><BR>update_def = "UPDATE TermDefinitions SET TermDefinitions.Definition = " & chr(34) & new_def & chr(34) & " WHERE TermDefinitions.Term = &#039" & search_term & "&#039" <BR>Set rs = conn.Execute(update_def)<BR><BR>:-)<BR>baby johnson

Posting Permissions

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