Results 1 to 3 of 3

Thread: RecordCount

  1. #1
    Ali Guest

    Default RecordCount

    I have a question about the sql server, is the recordcount and absolutepage in access different with in SQL Server? I&#039ve try to use it, and the result is different when i&#039m using access and sql server with the same record.. (in access recordcount=6 but in sql server recourdount=-1)

  2. #2
    Franco Guest

    Default RE: RecordCount

    For SQL Server, you probably want to use a different cursor than the default (forward-only) one. Forward-only does not allow you to do a straightforward recordcount but you can get at it by looping eg<BR><BR>Dim x<BR>x=0<BR>Do Until MyRecordset.EOF<BR> x=x+1<BR> MyRecordset.MoveNext<BR>Loop<BR>Response.Write "There are " & x & " records."<BR><BR>Look up cursors and recordset-opening parameters in Books Online.<BR><BR>hth<BR><BR>F.<BR><BR>

  3. #3
    Ali Guest

    Default RE: RecordCount

    Thank you Franco for your help... and now it&#039s work<BR>i&#039m using the adOpenStatic and adLockReadOnly<BR>

Posting Permissions

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