INDEXED Verb - Create INDEXED File

Syntax

INDEXED fileid,records,recsize{,ERR=lineref}

Description

The INDEXED verb creates an indexed file to the given specifications.

Parameter

Description

fileid

Name of the new file; must be unique.

records

Number of records to be allocated; must be an integer. For a dynamically allocated file, specify 0.

recsize

Size of each record in bytes and must be an integer in the range of 1 to 32767. The total size of the file cannot exceed (2^31)-1 bytes. The number of bytes required for an indexed file may vary from system to system. Multiplying records by recsize provides an accurate estimate of the number of bytes needed for an indexed file.

ERR=lineref

Branch to be taken if an error occurs during execution.

PRO/5 takes the optional ERR= branch, if a problem occurs while creating the file.

In an indexed file, records can be accessed either sequentially or randomly by record number.

Example

1000 INDEXED "TEST2",300,190,ERR=9400