COBOL Manual for TNS/E Programs (H06.08+, J06.03+)
• A file code
• An exclusion mode (EXCLUSIVE, SHARED, or PROTECTED) for reading and writing (but it
does not override any exclusion mode that the program explicitly specifies)
The ASSIGN command Example 259 specifies that the file that the program calls NEWFILE has
the system file name \AKRON.$SLB.MAJ.NEWFILE, is allocated five file pages, is an EDIT file
(type 101), and EXCLUSIVE exclusion mode (unless the OPEN statement that opens the file specifies
a different exclusion mode).
Example 259 ASSIGN Command
ASSIGN PROG1.NEWFILE,
\AKRON.$SLB.MAJ.NEWFILE,
EXT 5,
CODE 101,
EXCLUSIVE
You can also specify file characteristics with a DEFINE. For details on specifying file characteristics
with either the ASSIGN command or DEFINEs, see ASSIGN Command (page 582) and DEFINEs
(page 593).
Overriding the NONSTOP Directive
If your program was compiled with a NONSTOP directive (which causes it to execute as a process
pair), and you want to override the NONSTOP directive (until you have debugged the program,
for example), you must execute the command PARAM NONSTOP OFF before executing your
program. The PARAM NONSTOP OFF command is:
PARAM NONSTOP OFF
You can use a single PARAM command to do several things; for example, this PARAM command
overrides the NONSTOP directive and enables USE DEBUGGING SECTIONS:
PARAM NONSTOP OFF, DEBUG ON
For another example of a PARAM command that does several things, see Specifying Waited
Input-Output (page 823).
Specifying a Default Input-Output Device
First, verify that you want to specify a default input-output device. The alternative is to specify
separate default input and output devices.
The default input device (or the default input-output device) provides input to unqualified ACCEPT
statements (those without FROM clauses).
The default output device (or the default input-output device) displays run-time diagnostic messages
and output from unqualified DISPLAY statements (those without UPON clauses).
If a program has unqualified ACCEPT statements, the default input device (or the default input-output
device) must be a disk file, terminal, or process. If a program has unqualified DISPLAY statements,
the default output device (or the default input-output device) must be a disk file, terminal, process,
or printer. If a program has both unqualified ACCEPT statements and unqualified DISPLAY
statements, the default input-output device must be a terminal or process.
If you want separate default input and output devices, do not specify a default input-output device.
See Specifying Default Input and Output Devices.
If you want a default input-output device other than your home terminal, specify the default
input-output device as explained in the CRE Programmer’s Guide.
If default input-output device is a system file name, the file must exist before you execute the program.
If the default input-output device is a DEFINE name, you must add it before you execute the program
822 Executing and Debugging HP COBOL Programs










