crymedry
MIS
- Nov 19, 2003
- 54
can someone please help with this, i am just running an update statement on a databse, i have 2 statements to run, a select and an update statement, but i keep getting a syntax error telling that i am missing quotes ... can someone please tell me what i am doing wrong?
here is the code:
'define sql statements
StrGet="SELECT * FROM Issues WHERE [_id] = " & frm_misId & ""
StrInsert="UPDATE Issues SET _detailSituation=" & frm_misDetail & ", _solution=" & frm_misDetail & ", _status=" & frm_misStatus & ""
'create a connection
Set objConn=Server.CreateObject("ADODB.Connection")
objConn.Open "DSN=miskb"
Set objCmd=Server.CreateObject("ADODB.Command")
Set objCmd.ActiveConnection=objConn
objCmd1.CommandText= ""&StrGet&""
objCmd2.CommandText= ""&StrInsert&""
'execute the statements above
objCmd1.Execute
objCmd2.Execute
here is the error:
Error Type:
Microsoft VBScript runtime (0x800A01A8)
Object required: ''
/Scripts/mis/mis_update.asp, line 48
thanks for any help!!!!
here is the code:
'define sql statements
StrGet="SELECT * FROM Issues WHERE [_id] = " & frm_misId & ""
StrInsert="UPDATE Issues SET _detailSituation=" & frm_misDetail & ", _solution=" & frm_misDetail & ", _status=" & frm_misStatus & ""
'create a connection
Set objConn=Server.CreateObject("ADODB.Connection")
objConn.Open "DSN=miskb"
Set objCmd=Server.CreateObject("ADODB.Command")
Set objCmd.ActiveConnection=objConn
objCmd1.CommandText= ""&StrGet&""
objCmd2.CommandText= ""&StrInsert&""
'execute the statements above
objCmd1.Execute
objCmd2.Execute
here is the error:
Error Type:
Microsoft VBScript runtime (0x800A01A8)
Object required: ''
/Scripts/mis/mis_update.asp, line 48
thanks for any help!!!!