|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
|||
|
|||
|
Wow. This has gotten extremely frustrating. I cannot for the life of me figure out how to use ASP. At least to update...
here is the code I'm using (and I'm only trying to update one field!) <% dim connect dim output dim update_sql dim id id = Request.Form("id") 'Start SQL update_sql = "UPDATE tblApartment SET" 'Update status IF len(Request.Form("status")) THEN update_sql = update_sql & " Status = '" & _ Request.Form("status") & "'" END IF 'Update added_by 'Set the where clause update_sql = update_sql & " WHERE ID = '" & _ id & "'" Set connect = Server.CreateObject("ADODB.connection") connect.Open "DSN=mydsn" Set output = Server.CreateObject("ADODB.Recordset") output.Open update_sql, connect Response.Write "<hr noshade>The following insert string was executed " Response.Write update_sql connect.close set connect = Nothing %> And here is the error Microsoft OLE DB Provider for ODBC Drivers error '80040e07' [Microsoft][ODBC Microsoft Access Driver] Data type mismatch in criteria expression. If you can offer up any help... PLEASE DO! I'm pulling out hairs here
__________________
Hope you are having a good day. |
|
#2
|
|||
|
|||
|
ok
It is indeed an autonumber field...
so do you mind letting me know the proper syntax? Thanks! |
|
#3
|
|||
|
|||
|
where id=" & id get rid of the quotes
|
|
#4
|
|||
|
|||
|
Thanks
That's it. Starting to get the hang of the new code. Switching from CFMX to ASP wasn't as easy as I thought
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > new to asp... can't figure out update |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|