Updating Records

Results 1 to 2 of 2

Thread: Updating Records

  1. #1
    Mahloch Guest

    Default Updating Records

    I am using the following code to open a recordset that will then have a field updated...<BR><BR>dim objStud<BR>set objStud = server.createobject("ADODB.Recordset")<BR>strSql = "SELECT Stu_ID, Stu_Units_Pending, Stu_Units_Complete FROM Student WHERE Stu_ID = &#039" & strID & "&#039"<BR>objStud.open strSql, strConnect, adOpenDynamic ,adLockOptimistic ,adCmdText<BR><BR>and keep getting the following error...<BR><BR>Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.<BR><BR>What baffles me is that I have used virtuall identical code on another page and had no problems. <BR><BR>I have tried to not use any arguments other that source and active connection, however, it bombs when trying to actually update the record I need to update, obviously because the recordset is opened as read-only, but I get an error saying the<BR><BR>"object or provider is not capable of performing requested operation"<BR><BR>this would be...<BR><BR>objStud("Stu_Units_Pending").value = units<BR>objStud.Update<BR><BR>Any advice would be greatly appreciated.<BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Updating Records

    In noticed one thing straight away, you&#039ve put quotes round (what i assume to be, or what should be) a numeric value in your SQL statement. that would cause an error like this<BR><BR>j

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts