Intel® Fortran Compiler 18.0 Developer Guide and Reference

OPEN: RECORDTYPE Specifier

The RECORDTYPE specifier indicates the type of records in a file. It takes the following form:

RECORDTYPE = typ

typ

Is a scalar default character expression that evaluates to one of the following values:

'FIXED'

Indicates fixed-length records.

'VARIABLE'

Indicates variable-length records.

'SEGMENTED'

Indicates segmented records.

'STREAM'

Indicates stream-type variable length data with no record terminators.

'STREAM_LF'

Indicates stream-type variable length records, terminated with a line feed.

'STREAM_CR'

Indicates stream-type variable length records, terminated with a carriage return.

'STREAM_CRLF'

Indicates stream-type variable length records, terminated with a carriage return/line feed pair.

When you open a file, default record types are as follows:

'FIXED'

For relative files

'FIXED'

For direct access sequential files

'STREAM_LF'

For formatted sequential access files on Linux* and macOS* systems

'STREAM_CRLF'

For formatted sequential access files on Windows systems

'VARIABLE'

For unformatted sequential access files

A segmented record is a logical record consisting of segments that are physical records. Since the length of a segmented record can be greater than 65,535 bytes, only use segmented records for unformatted sequential access to disk or raw magnetic tape files.

Files containing segmented records can be accessed only by unformatted sequential data transfer statements.

If an output statement does not specify a full record for a file containing fixed-length records, the following occurs: