|
-
Oct 6th, 2002, 09:02 PM
#1
Thread Starter
New Member
ASP SQL Error
Hi All,
I'm trying to run the following query.
UpdateSubjectRS.open "tblEnrol", conn, 2, 2
sql_query = "SET Taken = (tblgroup.taken + 1) WHERE tblgroup.subjid = '" & SubCode & "' AND tblgroup.grpNo = " & TutGrp & ";"
UpdateSubjectRS.update sql_query, Conn
I have tried many combinations of the above 3 lines and have allways got the same error.
ADODB.Recordset (0x800A0BB9)
Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.
Can any one tell me why this doesn't work??
Thanks
-
Oct 7th, 2002, 02:16 AM
#2
Fanatic Member
Try This
sql_query = "update tblEnrol "
sql_query = sql_query & " SET Taken = (tblgroup.taken + 1) WHERE tblgroup.subjid = '" & SubCode & "' AND tblgroup.grpNo = " & TutGrp & ";"
UpdateSubjectRS.open sql_query, Conn
OR also this is possilbe
sql_query = "update tblEnrol "
sql_query = sql_query & " SET Taken = (tblgroup.taken + 1) WHERE tblgroup.subjid = '" & SubCode & "' AND tblgroup.grpNo = " & TutGrp & ";"
conn.execute sql_query
-
Oct 7th, 2002, 05:56 PM
#3
Thread Starter
New Member
That Worked thanks!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|