Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Advantage CA-Clipper Guide v5.5 - aofkeygoto() http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 aofKeyGoto()
 Position to the specified logical record that passes the Advantage
 Optimized Filter and is within the index scope
------------------------------------------------------------------------------

Syntax

     aofKeyGoto( <nLogicalRecNo> ) -> NIL

     <nLogicalRecNo>  The logical record number to position to.

Returns

     NIL.

Description

     aofKeyGoto() positions to the n'th record which meets the
     system-owned filter condition AND which is within the scope of the
     current index.

     If the current index contains a FOR clause, is UNIQUE, or in some
     other way has fewer than all records for the table in it,
     then aofKeyGoto() will only use those records which meet the filter
     condition and are contained in the index.

     aofKeyGoto() also obeys the current index scope, if one exists.  So,
     aofKeyGoto() will only use the records which meet the filter
     condition and those that fall within the current index scope.

Example

     INDEX ON age TO age FOR last = 'J'
     INDEX ON salary TO salary

     USE employee INDEX age, salary

     // Create a system-owned filter
     aofSetFilter( "salary >= 75000" )

     // Get the number of records with salary >= 75000 and who's
     //  last name starts with 'J'
     nCnt := aofKeyCount( "age" )

     // Go to the halfway point
     aofKeyGoto( nCnt / 2 )


See Also: aofKeyCount()

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