インテル® Fortran コンパイラー 19.0 デベロッパー・ガイドおよびリファレンス

OPEN Statement Specifiers

The OPEN statement connects an external file to a unit, creates a new file and connects it to a unit, creates a preconnected file, or changes certain properties of a connection. For more information, see OPEN.

The following table summarizes the OPEN statement specifiers and contains links to their descriptions:

OPEN Statement Specifiers and Values

Specifier

Values

Function

Default

ACCESS

'DIRECT'

'SEQUENTIAL'

'STREAM'

'APPEND'

Access mode

'SEQUENTIAL'

ACTION

(or MODE)

'READ'

'WRITE'

'READWRITE'

File access

'READWRITE'

ASSOCIATEVARIABLE

var

Next direct access record

No default

ASYNCHRONOUS

'YES'

'NO'

Asynchronous I/O

'NO'

BLANK

'NULL'

'ZERO'

Interpretation of blanks

'NULL'

BLOCKSIZE

n_expr

Physical I/O transfer size

131,072 bytes

BUFFERCOUNT

n_expr

Number of I/O buffers

One

BUFFERED

'YES'

'NO'

Buffering for WRITE operations; buffering for READ operations on variable length, unformatted, input records

'NO' 1

CARRIAGECONTROL

'FORTRAN'

'LIST'

'NONE'

Print control

Formatted: 'LIST'2

Unformatted: 'NONE'

CONVERT

'LITTLE_ENDIAN'

'BIG_ENDIAN'

'CRAY'

'FDX'

'FGX'

'IBM'

'VAXD'

'VAXG'

'NATIVE'

Numeric format specification

'NATIVE'

DECIMAL

'COMMA'

'POINT'

Decimal edit mode

'POINT'

DEFAULTFILE

c_expr

Default file pathname

Current working directory

DELIM

'APOSTROPHE'

'QUOTE'

'NONE'

Delimiter for character constants

'NONE'

DISPOSE(or DISP)

'KEEP' or 'SAVE'

'DELETE'

'PRINT'

'PRINT/DELETE'

'SUBMIT'

'SUBMIT/DELETE'

File disposition at close

'KEEP'

ENCODING

'UTF-8'

'DEFAULT'

Encoding form for a file

'DEFAULT'

ERR

label

Error transfer control

No default

FILE(or NAME)

c_expr

File pathname (file name)

fort.n 3

FORM

'FORMATTED'

'UNFORMATTED'

'BINARY'

Format type

Depends on ACCESS setting

IOFOCUS

.TRUE.

.FALSE.

Active window in QuickWin application

.TRUE.4

IOSTAT

var

I/O status

No default

MAXREC

n_expr

Direct access record limit

No limit

NEWUNIT

var

Returns automatically chosen, unused, unit number

No default

NOSHARED

No value

File sharing disallowed

L*X, M*X: SHARED

W*32: Not shared

ORGANIZATION

'SEQUENTIAL'

'RELATIVE'

File organization

'SEQUENTIAL'

PAD

'YES'

'NO'

Record padding

'YES'

POSITION

'ASIS'

'REWIND'

'APPEND'

File positioning

'ASIS'

READONLY

No value

Write protection

No default

RECL

(or RECORDSIZE)

n_expr

Record length

Depends on RECORDTYPE,ORGANIZATION, and FORM settings 5

RECORDTYPE

'FIXED'

'VARIABLE'

'SEGMENTED'

'STREAM'

'STREAM_CR'

'STREAM_LF'

Record type

Depends on ORGANIZATION, CARRIAGECONTROL, ACCESS, and FORM settings

ROUND

'UP'

'DOWN'

'ZERO'

'NEAREST'

'COMPATIBLE'

'PROCESSOR_DEFINED'

Rounding mode

'PROCESSOR_DEFINED'

SHARE

'DENYRW'

'DENYWR'5

'DENYRD'6

'DENYNONE'

File locking

'DENYWR' 7

SHARED

No value

File sharing allowed

L*X, M*X: SHARED

W*S: Not shared

SIGN

'PLUS'

'SUPPRESS'

'PROCESSOR_DEFINED'

Plus sign mode

'PROCESSOR_DEFINED'

STATUS(or TYPE)

'OLD'

'NEW'

'SCRATCH'

'REPLACE'

'UNKNOWN'

File status at open

'UNKNOWN' 8

TITLE

c_expr

Title for child window in QuickWin application

No default

UNIT

n_expr

Logical unit number

No default; an io-unit must be specified

USEROPEN

func

User program option

No default

1 The default is also 'NO' when reading variable length, unformatted records whose length exceeds that of the block size specified for the file.

2 If you use the compiler option specifying OpenVMS defaults, and the unit is connected to a terminal, the default is 'FORTRAN'.

3 n is the unit number.

4 If unit '*' is specified, the default is .FALSE.; otherwise, the default is .TRUE..

5 On Linux* and macOS* systems, the default depends only on the FORM setting.

6 W*S

7 The default differs under certain conditions (see SHARE Specifier).

8 The default differs under certain conditions (see STATUS Specifier).

Key to Values

   c_expr: A scalar default character expression
   func:   An external function
   label:  A statement label
   n_expr: A scalar numeric expression
   var:    A scalar integer variable

See Also