Where allowed to run: All environments (*ALL) Threadsafe: Conditional |
Parameters Examples Error messages |
The Change Prestart Job (CHGPJ) command changes the job attributes of the prestart job in which this command is issued to those in the job description specified in the prestart job entry, or to those in the job description specified in the user profile of the current user. When a program start request is received, the system will set the current user to the user profile specified in the program start request. The current user may subsequently be set to a different value by the Set Profile (QWTSETP) API.
Restrictions:
Considerations for Attribute Thread Safety:
This command is intended to be used to change the job attributes for the prestart job that the command was issued in. All of the attributes are scoped to the job.
The Threadsafe column of the following table indicates whether the attributes can be changed in a manner that is threadsafe.
Yes: - Attributes marked with this value are considered to be threadsafe. These attributes can be changed safely by issuing this command from either the initial thread or from a secondary thread.
No: - Attributes marked with this value are not threadsafe. An attempt to change these attributes will be denied if multiple threads are active.
Attribute and Thread Safety Table:
Attribute Threadsafe ---------------------------- ---------- Job accounting code (ACGCDE) No Output priority (OUTPTY) Yes Output queue name (OUTQ) Yes Print text (PRTTXT) Yes Printer device name (PRTDEV) Yes |
Top |
Keyword | Description | Choices | Notes |
---|---|---|---|
OUTPTY | Output priority (on OUTQ) | *SAME, *PGMSTRRQS, *PJE | Optional |
PRTTXT | Print text | *SAME, *PGMSTRRQS, *PJE | Optional |
PRTDEV | Print device | *SAME, *PGMSTRRQS, *PJE | Optional |
OUTQ | Output queue | *SAME, *PGMSTRRQS, *PJE | Optional |
ACGCDE | Accounting code | *SAME, *PGMSTRRQS, *PJE | Optional |
Top |
Specifies the output priority for spooled output files that are produced by this job. Only those spooled output files which are on output queues in the library name space of the thread issuing this command will be changed.
Top |
Specifies the text that is printed at the bottom of each page of printed output and on separator pages.
Top |
Specifies the name of the default printer device for this job.
Top |
Specifies the name of the output queue that is used for spooled output produced by the prestart job. This does not affect files previously created by the prestart job.
Top |
Specifies the accounting code that is used for this job.
Top |
Example 1: Changing the Output Priority
CHGPJ OUTPTY(*PGMSTRRQS)
This command changes the output priority for spooled files produced by this job to the output priority in the job description associated with the user profile of the current user.
Example 2: Changing the Output Queue
CHGPJ OUTQ(*PJE)
This command changes the output queue for spooled files produced by this job to the output queue in the job description specified in the prestart job entry.
Top |
*ESCAPE Messages
Top |