Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- CA-Clipper 5.2 . Technical Reference - <b>sort()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 sort()
 Physically reorder a database
------------------------------------------------------------------------------
 Prototype

     ERRCODE sort(
                   WORKAREAP wa,
                   DBSORTINFOP dbSortInfo
                 )

 Arguments

     wa is a pointer to self.

     dbSortInfo is a pointer to a structure containing information on how
     to sort the workarea table.

 Description

     Performs a physical reorder of the database by copying records from the
     current workarea to another database file in sorted order as specified
     in dbSortInfo.  sort() performs as much of its operation as possible in
     memory, then it spools to a uniquely named temporary disk file.  This
     temporary file can be as large as the size of the source database file.
     It then overwrites the original database with the newly sorted data.

 Default Behavior

     You must implement the default behavior of this method through a
     subclass.

 Implementation Notes

     .  Since a sort must traverse the entire data store, the buffer
        for the current workarea must goCold() before any sort() operation
        can take place.  Further, in a shared environment, you can only
        implement this method after the proper locks are established.

 Files:  Header file is Rdd.api.


See Also: DBSORTINFO WORKAREA goCold()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson