HP RPG/XL Programmer's Guide (30318-90001)

3-: 36
* Sequentially (not in key order)
* Sequentially by full key values
* Randomly by key value
Reading a TurboIMAGE Data Set Sequentially. Since TurboIMAGE does not
maintain the sequential order of keys in its data sets, you cannot read
the entire data set from beginning to end by a specific key. However,
you can retrieve all of the records in their stored unsorted sequence.
This may be useful, for example, for extracting data set records for a
sort.
Figure 3-25 shows how to retrieve all of the records in the TurboIMAGE
data set, D-ACCOUNTS (see the schema for this data set in Figure 3-23),
and how to display the first four fields in them.
.
Figure 3-25. Reading a TurboIMAGE Data Set Sequentially
Comments
1 This line defines the TurboIMAGE data set file, DACCOUNT.
2 This line defines the database containing D-ACCOUNTS and the
security provisions for accessing the database.
Column 53 is K to indicate that this is a Continuation line.
Columns 54-65 identify MARKET as the TurboIMAGE database that is
used.
Column 66 is 6 to indicate Open Mode 6 - Shared Read Access.
Column 67 is 2 to specify Input/Output Mode 2 - Serial Read.
3 This line establishes the password for the database.
Columns 54-65 contain LEVEL READER to specify the password,
READER. This password establishes a user class identification