R
RobA
Sorry for posting again, I am having a bad day.
I have field in the SQL database defined as a "decimal."
I am trying to update using the following:- but I just keep getting the
Varchar to Numeric error - the other fields are nvarchar but I am not
updating them.
I tried removing the quotes from the value but then I get an unrecognised
column error.
Any help will be greatly appreicated.
Dim cmd1, strSQL1, UID, QIDVal,ScoreVal
ScoreVal = 0
UID = Session("UID")
QIDVal = Request.Form("QUID")
ScoreVal = Request.Form("Value")
Set cmd1 = CreateObject ("ADODB.Command")
strSQL1 = "UPDATE iaVals SET "
strSQL1 = strSQL1 & "eScore= 'ScoreVal'"
strSQL1 = strSQL1 & " WHERE iauID = 'UID' AND QID = 'QIDVal'"
cmd.ActiveConnection = objConn
cmd.CommandText = strSQL1
cmd.Execute
I have field in the SQL database defined as a "decimal."
I am trying to update using the following:- but I just keep getting the
Varchar to Numeric error - the other fields are nvarchar but I am not
updating them.
I tried removing the quotes from the value but then I get an unrecognised
column error.
Any help will be greatly appreicated.
Dim cmd1, strSQL1, UID, QIDVal,ScoreVal
ScoreVal = 0
UID = Session("UID")
QIDVal = Request.Form("QUID")
ScoreVal = Request.Form("Value")
Set cmd1 = CreateObject ("ADODB.Command")
strSQL1 = "UPDATE iaVals SET "
strSQL1 = strSQL1 & "eScore= 'ScoreVal'"
strSQL1 = strSQL1 & " WHERE iauID = 'UID' AND QID = 'QIDVal'"
cmd.ActiveConnection = objConn
cmd.CommandText = strSQL1
cmd.Execute