READKEY


7.8

The READKEY instruction returns the key associated with the last indexed record to a variable. The instruction uses the following format:

 

 

[label]

READKEY

{ifile},{key}

 

Where:

label

Optional. A Program Execution Label.

ifile

Required. A previously defined and opened IFILE variable from which the last key accessed is returned.

key

Required. A previously defined Character String Variable that returns the key associated with the last indexed record.

Flags Affected: NONE

Note the following:

  1. The key associated with the last record processed for the given ISAM file is moved to the variable specified.

 

 

See Also: Example Code, Disk I/O Instructions

 



PL/B Language Reference READ, READTAB, READLK (IFILE) READKG, READKGTB, READKGLK