Identifying the last record

Results 1 to 2 of 2

Thread: Identifying the last record

  1. #1
    Sree.S Guest

    Default Identifying the last record

    Can someone tell me how to identity the last record ?<BR><BR>The EOF = true indicates whether the current record position is after the last record in a Recordset object. But how to know the currrent record being listed is the last record [one record before EOF] ???<BR><BR>Thanks in Advance!!<BR>

  2. #2 Guest

    Default Depends!

    RecordSet.MoveLast will move your cursor to the last record of the recordset.<BR><BR>Alternatively you could make you query so it sorts the records in descending order. Then the first record would be the last record. If you only want the last record you could use an sql command like this:<BR><BR>Select top 1 * from Tbl Order by KeyField desc<BR><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