don
09-11-2002, 09:35 PM
I'm new to connecting to Oracle with ADO so pardon if this is super basic.
The following code hangs right at the "with" clause. I have tried it with and without the "FOR UPDATE" clause.
Anybody have any ideas?
Thanks,
Don
=========
Set objDbConn = Server.CreateObject( "ADODB.Connection" )
objDbConn.Open "DSN=BO1;uid=sa;pwd=sa;"
Set rsD = Server.CreateObject("ADODB.Recordset")
sSQL = "SELECT * " & _
"FROM USER_GROUP " & _
"WHERE EMPL_ID='" & UserName & "'" & _
"FOR UPDATE"
rsD.Open sSQL, objDbConn, adOpenDynamic, adLockOptimistic, adCmdText
If rsD.EOF Then
Response.Redirect "userInvalid.asp"
Else
With rsD
.Fields("GROUP_CDE") = UserGroup
.Fields("LAST_UPD_DTM") = date()
.Update
rsD.Close
End With
End If
The following code hangs right at the "with" clause. I have tried it with and without the "FOR UPDATE" clause.
Anybody have any ideas?
Thanks,
Don
=========
Set objDbConn = Server.CreateObject( "ADODB.Connection" )
objDbConn.Open "DSN=BO1;uid=sa;pwd=sa;"
Set rsD = Server.CreateObject("ADODB.Recordset")
sSQL = "SELECT * " & _
"FROM USER_GROUP " & _
"WHERE EMPL_ID='" & UserName & "'" & _
"FOR UPDATE"
rsD.Open sSQL, objDbConn, adOpenDynamic, adLockOptimistic, adCmdText
If rsD.EOF Then
Response.Redirect "userInvalid.asp"
Else
With rsD
.Fields("GROUP_CDE") = UserGroup
.Fields("LAST_UPD_DTM") = date()
.Update
rsD.Close
End With
End If