Ciao, questa è la mia pagina
http://www.oratoriocividate.it/sonda.../sondaggio.asp
Come vedete, quando si vota mi compare questo messaggio
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Microsoft Access Driver] Operation must use an updateable query.
/sondaggio/sondaggio/sondaggio.asp, line 39
Questo è il pezzo:
<%
Dim cn, rs, sql
dim strCode
strCode="innovatel"
Set cn = Server.CreateObject("ADODB.Connection")
strCn="driver={Microsoft Access Driver (*.mdb)}; "
strCn=strCn & " DBQ=" & Server.MapPath(path)
strCn=strCn & ";pwd=" & strCode
Cn.Open strCn
if Request.QueryString("action") = "vota" then
if Session("votato")<>1 then
Dim index
index = Request.QueryString("idx")
sql = "SELECT VOTI FROM Sondaggio WHERE ID=" &index
Set rs = cn.Execute(sql)
sql = "UPDATE Sondaggio SET VOTI=" &rs("VOTI")+1& " WHERE ID=" &index
cn.Execute(sql)
Session("votato") = 1
end if
Response.Redirect("sondaggio.asp")
end if
Qual è il problema? GRAZIE!!!!

Rispondi quotando