Function OrdListRebuild() Foundation

Rebuilds open index files in a work area.

Syntax
OrdListRebuild() --> NIL
Return

The return value of OrdListRebuild() is always NIL.

Description

The index function OrdListRebuild() rebuilds the open index files in a work area. When the function is used without the alias operator, the function rebuilds the open index files in the current work area. When the rebuild is complete, the data record pointer is positioned on the first logical record of the controlling index.

OrdListRebuild() differs from OrdCreate() in that only the sorting is rebuilt and the index file is not completely recreated. If the file header of the index file is defective, it cannot be repaired using OrdListRebuild(). In this case, the index file must be recreated with OrdCreate().

Examples
OrdListRebuild()
// In the example, a database file with three index files is 
// opened and the indexes are rebuilt using OrdListRebuild(). 

PROCEDURE Main 
   USE Customer INDEX CustA, CustB, CustC 

   OrdListRebuild() 

   CLOSE Customer 

RETURN 

Feedback

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.