Hour 14Indexed
Files
An Indexed
file is a file that allows access to data records by way of a Key
field. The file is said to be “Indexed” by this Key. Indexed
files are sometimes referred to as keyed files. In this hour, you learn the basics of Indexed
file handling, such as
• Defining an Indexed
file
• Handling Primary
and Alternate Keys
• Writing
records with an Indexed
file
• Using File Status
values
• Using Declaratives
A record in an Indexed
file contains at least one Key
field. This field is the index to the file. There must be at least one Key
field that contains a value that is unique. This Key
field is the Primary Key
. Each record in the file is uniquely identified by this Key
, which functions like a serial number. With this Key
you ...
Get Sams Teach Yourself COBOL in 24 Hours now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.