Hi,
I need help please
I am still not up to speed with ASP and I have a problem trying to update a database on line using this code
SQLstmt = "UPDATE br_stds SET "
SQLstmt = SQLstmt & "br_no='" & TRIM(Request.Form("br_no")) & "', "
SQLstmt = SQLstmt & "lclas='" & TRIM(Request.Form("lclas")) & "', "
SQLstmt = SQLstmt & "class2='" & TRIM(Request.Form("class2")) & "', "
SQLstmt = SQLstmt & "loco_name='" & TRIM(Request.Form("loco_name")) & "', "
SQLstmt = SQLstmt & "builder='" & TRIM(Request.Form("builder")) & "', "
SQLstmt = SQLstmt & "build_no='" & TRIM(Request.Form("build_no")) & "', "
SQLstmt = SQLstmt & "mm_built='" & TRIM(Request.Form("mm_built")) & "', "
SQLstmt = SQLstmt & "yy_built='" & TRIM(Request.Form("yy_built")) & "', "
SQLstmt = SQLstmt & "mm_wdn='" & TRIM(Request.Form("mm_wdn")) & "', "
SQLstmt = SQLstmt & "yy_wdn='" & TRIM(Request.Form("yy_wdn")) & "', "
SQLstmt = SQLstmt & "code='" & TRIM(Request.Form("code")) & "', "
SQLstmt = SQLstmt & "last_shed='" & TRIM(Request.Form("last_shed")) & "', "
SQLstmt = SQLstmt & "mm_cut='" & TRIM(Request.Form("mm_cut")) & "', "
SQLstmt = SQLstmt & "yy_cut='" & TRIM(Request.Form("yy_cut")) & "', "
SQLstmt = SQLstmt & "cut='" & TRIM(Request.Form("cut")) & "', "
SQLstmt = SQLstmt & "notes='" & TRIM(Request.Form("notes")) & "' "
SQLstmt = SQLstmt & " WHERE ID=" & TRIM(Request.Form("Recordid"))
%>
SQL statement: <%=SQLstmt%>
<%
Conn.Execute (SQLstmt)
When I run this piece of code the SQL statement prints out so
SQL statement: UPDATE br_stds SET br_no='71000', lclas='8P', class2='', loco_name='Duke of Gloucester', builder='Crewe', build_no='E486', mm_built='May', yy_built='1954', mm_wdn='Nov', yy_wdn='1962', code='5A', last_shed='Crewe North', mm_cut='Intact', yy_cut='', cut='Preserved', notes='test' WHERE ID=57
Now I cannot find anything wrong with the statement or the request BUT i get this error message
"Microsoft JET Database Engine error '80040e07'
Data type mismatch in criteria expression.
Line 257 "
which is the line Conn.Execute (SQLstmt)
Can anyone please point me in the right direction

Regards Topshed