Function DbGoBottom() Foundation
Sets the record pointer to the last logical record.
DbGoBottom() --> NILThe return value of DbGoBottom() is always NIL.
The database function DbGoBottom() moves the record pointer of a work area to the last logical record. When the function is used without the alias operator, the record pointer is moved in the current work area.
The command GO BOTTOM can be used instead of DbGoBottom(). GO BOTTOM is only effective in the current work area.
After termination of the function DbGoBottom(), the record pointer is positioned at the last logical record. The last record is determined by the controlling index and/or by the active filter condition. When neither filter nor index exist, the function moves the record pointer to the last physical record.
// In the example, DbGoBottom() is used on a file which 
// is opened first without and then with an index. 
// After each call to DbGoBottom() the record pointer 
// references another record. 
PROCEDURE Main 
   USE Customer NEW EXCLUSIVE 
   Customer->( DbGoBottom() ) 
   ? Customer->( RecNo()   )    // result: 100 
   ? Customer->( LastRec() )    // result: 100 
   ? Customer->LastName         // result: King 
   Customer->( DbSkip()  ) 
   ? Customer->( RecNo() )      // result: 101 
   ? Customer->( Eof()   )      // result: .T. 
   INDEX ON LastName TO CustA 
   SET INDEX TO CustA 
   Customer->( DbGoBottom() ) 
   ? Customer->( RecNo()   )   // result: 43 
   ? Customer->( LastRec() )   // result: 100 
   ? Customer->LastName        // result: Zimmerman 
   Customer->( DbSkip()  ) 
   ? Customer->( RecNo() )     // result: 101 
   ? Customer->( Eof()   )     // result: .T. 
   CLOSE Customer 
RETURN 
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.
