The file is opened to allow only output operations. When the file is successfully opened, it contains no records.
Under OPTION(*NOBLK), the compiler generates code to block output records and unblock input records if the following conditions are satisfied:
The BLOCK CONTAINS clause does not control the blocking factor for any files except tape files.
Device type FORMATFILE and PRINTER can only be opened for output.
Related Information:
If dynamic file creation has been specified, then the OPEN statement will create the file if it is not already available.
+-------------------------------IBM Extension--------------------------------+
Only a physical file is cleared when opened for OUTPUT. When the file is successfully opened, it contains no records. If an attempt is made to open a logical file for OUTPUT, the file is opened but no records are deleted. The file is treated as though the EXTEND phrase had been specified. To clear a logical file, all the members on which the logical file is based should be cleared.
+----------------------------End of IBM Extension----------------------------+
(C) Copyright IBM Corporation 1992, 2006. All Rights Reserved.