I have a problem with uploading file into SQL 2005 DB using IIS 6.0
webserver, this code was working in SQL 2000 Db and IIS 5.0. Can you please
help me to see what the problem is.
Error msg :
Microsoft OLE DB Provider for ODBC Drivers error '80040e23'
[Microsoft][ODBC SQL Server Driver][SQL Server]The cursor does not include
the table being modified or the table is not updatable through the cursor.
/uploadnewreques t.asp, line 158
Code:
rstrNewFiles = ""
Set rstrNewFiles = Server.CreateOb ject("ADODB.Rec ordset")
rstrNewFiles.Op en "tblrFiles" , Conn, 3, 3
Set cmd = Server.CreateOb ject("ADODB.Com mand")
with cmd
.ActiveConnecti on = conn
.Parameters.Ref resh
.CommandTimeout = 3600
End With
rstrNewFiles.Ad dNew
rstrNewFiles("P rojectNo") = strprojNumber
rstrNewFiles("p rojectID") = Uploader.Form(" ProjNo")
rstrNewFiles("F ileName") = File.FileName
rstrNewFiles("F ileSize") = File.FileSize
rstrNewFiles("C reatedBy") = strUSer
rstrNewFiles("I PAddress") = varIPAddress
rstrNewFiles("D ateCreated") = strDateCreated
If varFileExtensio n = "doc" then
rstrNewFiles("C ontentType") = "applicatio n/msword"
Else
rstrNewFiles("C ontentType") = File.ContentTyp e
End if
rstrNewFiles("F ileData").Appen dChunk File.FileData
Line 158 - rstrNewFiles.Up date
rstrNewFiles.Cl ose
webserver, this code was working in SQL 2000 Db and IIS 5.0. Can you please
help me to see what the problem is.
Error msg :
Microsoft OLE DB Provider for ODBC Drivers error '80040e23'
[Microsoft][ODBC SQL Server Driver][SQL Server]The cursor does not include
the table being modified or the table is not updatable through the cursor.
/uploadnewreques t.asp, line 158
Code:
rstrNewFiles = ""
Set rstrNewFiles = Server.CreateOb ject("ADODB.Rec ordset")
rstrNewFiles.Op en "tblrFiles" , Conn, 3, 3
Set cmd = Server.CreateOb ject("ADODB.Com mand")
with cmd
.ActiveConnecti on = conn
.Parameters.Ref resh
.CommandTimeout = 3600
End With
rstrNewFiles.Ad dNew
rstrNewFiles("P rojectNo") = strprojNumber
rstrNewFiles("p rojectID") = Uploader.Form(" ProjNo")
rstrNewFiles("F ileName") = File.FileName
rstrNewFiles("F ileSize") = File.FileSize
rstrNewFiles("C reatedBy") = strUSer
rstrNewFiles("I PAddress") = varIPAddress
rstrNewFiles("D ateCreated") = strDateCreated
If varFileExtensio n = "doc" then
rstrNewFiles("C ontentType") = "applicatio n/msword"
Else
rstrNewFiles("C ontentType") = File.ContentTyp e
End if
rstrNewFiles("F ileData").Appen dChunk File.FileData
Line 158 - rstrNewFiles.Up date
rstrNewFiles.Cl ose