HELP: Write a file block-oriented (mainly open world)
TYPE: OBJECT
SYNTAX: BLK(NET.{},NAME/FILE='str'/STREAM/DUMMY,MODE=STOP/APPEND/OVERWRITE,EMPTY=INFO/WARNING/ERROR/DELETE,FALLOC(),REMOVE,RENAME='str',REMAIN,NOMKDIR,APPEND,FLUSH,FRCREC,ADDDLM,ACSTIM=num,MODTIM=num/ORIGINAL,ATTRIB(),PRNCTR=DETACH/RETAIN/ERASE/REPLACE,RPLFFD[=num],BINDMP,PREPRO[()...],POSTPRO/PSTPRO[()...])
This object defines the block-oriented write operation for files. This method writes the all data after any conversions as one chunk to the file. This is the most common and simplest way to write a file. This write method is useful for all non-record-oriented file formats.
If the block still contains a record length information, you can enforce a record-oriented write. It is also possible to add the system delimiter behind each record to produce a valid text block.
To retain the modification time of the original file, the modtime
parameter can be set to ORIGINAL.
STRING: NAME/FILE='str'/STREAM/DUMMY - Name/URL of file to write [auto]
STREAM - Read from stdin or write to stdoutDUMMY - Read EOF or write nothingNUMBER: MODE=STOP/APPEND/OVERWRITE - Error handling if the same file is used again [APPEND]
STOP - Stop processing with an errorAPPEND - Add the new data to the existing file or memberOVERWRITE - Overwrite the existing file or memberNUMBER: EMPTY=INFO/WARNING/ERROR/DELETE - Define special handling for empty files [NONE]
INFO - Print info to the logWARNING - Print warning to the log (completion code 1)ERROR - Stop procession with error and special completion codeDELETE - Delete the empty file (nothing written)SWITCH: REMAIN - Remain existing files (don't overwrite) [FALSE]SWITCH: NOMKDIR - Don't create path if path not exists [FALSE]SWITCH: APPEND - Append data to this file [FALSE]SWITCH: FLUSH - Enforce flush in front of close file [FALSE]SWITCH: FRCREC - Enforce record orientation on record oriented devices [FALSE]SWITCH: ADDDLM - Add a delimiter behind each record to produce a text block [FALSE]NUMBER: ACSTIM=num - Define the last access time for this fileNUMBER: MODTIM=num/ORIGINAL - Define the last modification time for this file
ORIGINAL - Copy modification time from the original fileNUMBER: RPLFFD=num - Replace form feeds, filling rest of page with empty records assuming n lines per page [60]SWITCH: BINDMP - Write dump for binary data [FALSE]