Results 1 to 3 of 3

Thread: Can't use sort property

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Sep 2000
    Posts
    219
    Why can't I use the sort property with ado recordsets in asp scripts? When I try, I get the following message:

    ADODB.Recordset error '800a0cb3'

    The operation requested by the application is not supported by the provider.

    /historyresponse.asp, line 30
    Why is this?

  2. #2
    Guru Clunietp's Avatar
    Join Date
    Oct 1999
    Location
    USA
    Posts
    1,844
    before you open your recordset, set the cursorlocation to adUseClient

    example

    Code:
    dim objRS
    
    const adUseClient = 3
    
    set objRS = server.createobject("ADODB.Recordset")
    
    objRs.CursorLocation = adUseClient
    objRs.Open "Select * from MyTable", "<connectionStringHere>"
    
    objRs.sort "myColumn"
    
    'etc etc.....
    Please note that this code is not entirely syntactically correct, as I whipped it off of the top of my head, but it should prove the point

    Tom

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Sep 2000
    Posts
    219
    Thanks Clunietp. It worked great.

Posting Permissions

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



Click Here to Expand Forum to Full Width