Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

error '80040e14' - Problem

Status
Not open for further replies.

Webflex

Technical User
Apr 20, 2001
101
GB
Hi People

DSN is this

Code:
dsn="DBQ=" & Server.Mappath("../db/csoprojects.mdb") 
& ";Driver={Microsoft Access Driver (*.mdb)};"
set conn=server.createObject("adodb.connection")
conn.open dsn

Case is this

Code:
case "update"
	id=request.form("id")
	orid=request.form("orid")
	lastname=request.form("lastname")
	datecreate=request.form("datecreate")
	clientid=request.form("clientid")
	projectdescription=request.form
("projectdescription")
	sql = "update users SET 
orid='"&orid&"',lastname='"&lastname&"',datecreate='"&datecr
eate&"',clientid='"&clientid&"',projectdescription='"&projec
tdescription&"' where id="&id
	'response.write sql'***debug
	conn.execute(sql)
	conn.close
	set conn = nothing
	response.redirect "search.asp"


HTML is this

Code:
  </tr><form action=&quot;editdel.asp?action=update&quot; 
method=&quot;post&quot;>
  
  <tr> 

    <td> <font face=&quot;Verdana&quot; size=&quot;2&quot;> Project 
Number:</font></td>
    <td> 
       <input type=&quot;text&quot; name=&quot;clientid&quot; size=&quot;2&quot; 
maxlength=&quot;2&quot; value=&quot;<%= orid %>&quot;><%= id %>
      
  </tr>
  <tr> 
    <td><font face=&quot;Verdana, Arial, Helvetica, sans-serif&quot; 
size=&quot;2&quot;>Client / Client 
      Contact.:</font></td>
    <td> 
	 
      <input type=&quot;text&quot; name=&quot;clientid&quot; size=&quot;20&quot; 
maxlength=&quot;20&quot; value=&quot;<%= clientid %>&quot;>
      <input type=&quot;text&quot; name=&quot;lastname&quot; size=&quot;20&quot; 
maxlength=&quot;20&quot; value=&quot;<%= lastname %>&quot;>
  </tr>
  <tr> 
    <td> <font face=&quot;Verdana, Arial, Helvetica, sans-serif&quot; 
size=&quot;2&quot;>Date Created.:</font></td>
    <td> 
      <input type=&quot;text&quot; name=&quot;datecreate&quot; size=&quot;20&quot; 
maxlength=&quot;20&quot; value=&quot;<%= datecreate %>&quot;>
  </tr>
  <tr> 
    <td> <font face=&quot;Verdana&quot; size=&quot;2&quot;> </font></td>
    <td>  
  </tr>
  <tr> 
    <td> <font face=&quot;Verdana&quot; size=&quot;2&quot;> Project 
Description:</font></td>
    <td> 
      <textarea name=&quot;projectdescription&quot; rows=&quot;5&quot; 
cols=&quot;50&quot;><%= projectdescription %>
 
You might try throwing some single quotes around the ID in your where clause:


where id=&quot;&id


I don't know if that will fix it but that seems to be where the error is pointing at. You might try it and see.
 
Is the form that you provided the one that is submitting the data or receiving it?

You have two input textboxes with the name 'clientid'.

Also, if this is the input form - you have no id field to complete your WHERE clause in the SQL statement of the editdel.asp page.

As jitter says if you are receiving the variables from a querystring you will need the single inverted comma's i.e. SQL ... . .. . WHERE id =&quot; & &quot;'&quot; & id & &quot;'&quot;

Hope that helps
 
Thanks guys, the problem was with the missing ID field in the update form, I wanted to display it but not have it update as this is fixed by an autonumber.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top