Results 1 to 3 of 3

Thread: Lock Type error

  1. #1
    Join Date
    Apr 2002

    Angry Unanswered: Lock Type error

    I am using ASP&ADO to Access a SQL 200 Server where the proper permissions have been allocated for the user and I keep getting this error message

    Error Type:
    ADODB.Recordset (0x800A0CB3)
    Current Recordset does not support updating. This may be a limitation of the provider, or of the selected locktype.

    I have tried all of the LockTypes and no change. I have tried a combination of all the lock types with the cursor types as well but still this error.

    Here is the code that does the work

    If rstHDD.EOF then
    Call RST_New(rstHDI) "HepDoseDate", Cnn, adOpenDynamic, adLockOptimistic
    If rstHDI.Supports(adAddNew) then
    response.write "Can add new rst"
    rstHDI.Fields("EmployeeID").Value = empid
    rstHDI.Fields("Consent").Value = consent
    rstHDI.Fields("Decline").Value = decline
    rstHDI.Fields("Shot1").Value = shot1
    rstHDI.Fields("Shot2").Value = shot2
    rstHDI.Fields("Shot3").Value = shot3
    response.write "Cannot add new rst"
    End If
    response.write " Updating"
    rstHDD.Fields("Consent").Value = consent
    rstHDD.Fields("Decline").Value = decline
    rstHDD.Fields("Shot1").Value = shot1
    rstHDD.Fields("Shot2").Value = shot2
    rstHDD.Fields("Shot3").Value = shot3
    End If

    I cannot addnew or update recordsets. Please let me know if you see the problem.

    the Call RST_New
    just sets the rst = server.createobject("ADODB.Recordset")

  2. #2
    Join Date
    Feb 2002
    If you have access to vb, I would run the same code and see if the problem persists. If it does, set a break point after the connection to the database is made and look at the locals view and look at the properties. You will see the provider information and it will tell if it is updatable or not. Also, I would try updating the same information using SQL Query Analyzer - logging in as the same user. I do not see the connection information as to how you are connecting - but I would also try the same code logged in as "sa".

    Good luck.

  3. #3
    Join Date
    May 2002
    did you include the vb constants file?

    if not, that might be the problem.

    you can also try "HepDoseDate", Cnn, 1, 2

    that should work.

    oh, just a tip, when you just say "HepDoseDate", you return the ENTIRE table. do a select statement that returns no records at all. like

    select * from HepDoseDate were PKID = 0

    since most identities start at 1, that should return 0 records.

Posting Permissions

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