Where allowed to run: All environments (*ALL) Threadsafe: No |
Parameters Examples Error messages |
The Work with Journal Attributes (WRKJRNA) command displays or prints the creation and operational attributes of a journal, including the name of the journal receiver currently attached to the journal. From the primary display, options or functions can be selected to display the names of all objects currently journaled to the journal, the names of all remote journals currently associated with this journal and detailed information about a remote journal, the receiver directory, or detailed information about a journal receiver; or to delete receivers from the receiver directory.
The command can also be used to generate an output file that lists journaled objects.
If output is printed with the job's spooled printer output with DETAIL(*OUTPUT) specified, all of the information that is optionally displayed is printed except:
When OUTPUT(*PRINT) is chosen, the DETAIL parameter can be used to subset the information printed. Specifying one or more of the values of *CURATR, *RCVDIR, *RMTJRN, *JRNFILE, *JRNAP, *JRNDTAQ, *JRNDTAARA, and *JRNIFS is allowed.
If output is directed to an output file, then only the journaled object information is written to the output file. When OUTPUT(*OUTFILE) is chosen, the DETAIL parameter can be used to subset the information sent to the output file. Specifying one or more of the values of *JRNFILE, *JRNAP, *JRNDTAQ, *JRNDTAARA, *JRNIFS and *IMPLICIT is allowed.
Top |
Keyword | Description | Choices | Notes |
---|---|---|---|
JRN | Journal | Single values: *INTSYSJRN Other values: Qualified object name |
Required, Positional 1 |
Qualifier 1: Journal | Name | ||
Qualifier 2: Library | Name, *LIBL, *CURLIB | ||
OUTPUT | Output | *, *PRINT, *OUTFILE | Optional, Positional 2 |
DETAIL | Detail | Single values: *OUTPUT Other values (up to 8 repetitions): *CURATR, *RCVDIR, *RMTJRN, *JRNFILE, *JRNAP, *JRNDTAARA, *JRNDTAQ, *JRNIFS, *IMPLICIT |
Optional |
OUTFILE | File to receive output | Qualified object name | Optional |
Qualifier 1: File to receive output | Name | ||
Qualifier 2: Library | Name, *LIBL, *CURLIB | ||
OUTMBR | Output member options | Element list | Optional |
Element 1: Member to receive output | Name, *FIRST | ||
Element 2: Replace or add records | *REPLACE, *ADD | ||
JRNID | Journal identification number | Character value | Optional |
Top |
Specifies the journal whose attributes are to be displayed.
This is a required parameter.
Single values
Note: You must have all object (*ALLOBJ) special authority to specify JRN(*INTSYSJRN).
Note: If the *INTSYSJRN value is specified, then OUTPUT(*OUTFILE) can not be specified and DETAIL(*OUTPUT) must be specified.
Note: If the *INTSYSJRN value is specified, the OUTFILE and DETAIL parameters cannot be specified.
Qualifier 1: Journal
Qualifier 2: Library
Top |
Specifies where the output from the command is sent.
Note: File QPDSPJNA is used for printed output. File QAWRKJRNA is the model output file. The format name is QJOWRKJRNA.
Top |
Specifies the type of information that is directed to the printer file or output file.
Single values
If OUTPUT(*PRINT) was selected, then DETAIL(*OUTPUT) will have the same meaning as selecting all of the following parameter values for DETAIL: *CURATR, *RCVDIR, *RMTJRN, *JRNFILE, *JRNAP, *JRNDTAQ, *JRNDTAARA, and *JRNIFS.
If OUTPUT(*OUTFILE) was selected, then DETAIL(*OUTPUT) will have the same meaning as selecting all of the following parameter values for DETAIL: *JRNFILE, *JRNAP, *JRNDTAQ, *JRNDTARA and *JRNIFS.
Other values (up to 8 repetitions)
Note: This value must be specified on the DETAIL parameter to get this information.
Top |
Specifies the database file to which the output of the command is directed. If the file does not exist, this command creates a database file in the specified library. If the file is created, the public authority for the file is the same as the create authority specified for the library in which the file is created. Use the Display Library Description (DSPLIBD) command to show the library's create authority.
Qualifier 1: File to receive output
Qualifier 2: Library
Note: If a new file is created, the system uses QAWRKJRNA in QSYS with the format name QJOWRKJRNA as a model.
Top |
Specifies the name of the database file member that receives the output of the command.
Element 1: Member to receive output
Element 2: Replace or add records
Top |
Specifies the five-character journal identification number (ID) of the internal system journal (*INTSYSJRN) to be displayed. Journal IDs are assigned by the system. The first two characters represent the journal type, and the last three characters are the auxiliary storage pool (ASP) identifier.
Note: The JRNID parameter can be specified only if JRN(*INTSYSJRN) is specified.
Following is a listing of journal types:
Top |
Example 1: Simple Command Example
WRKJRNA JRN(MYLIB/JRNLA)
This command allows you to work with the current journal attributes of JRNLA in library MYLIB.
Example 2: More Complex Commands for *PRINT
WRKJRNA JRN(YOURLIB2/JRNLB) OUTPUT(*PRINT) DETAIL(*OUTPUT) WRKJRNA JRN(YOURLIB2/JRNLB) OUTPUT(*PRINT) DETAIL(*CURATR *RCVDIR *JRNFILE *JRNAP *JRNDTAQ *JRNDTAARA *JRNIFS *RMTJRN)
These two commands print information related to the journal JRNLB in library YOURLIB2. Specifically they will print journal attribute information, information about the receivers associated with the journal, remote journal information, a list of files being journaled, a list of access paths being journaled, a list of data queues being journaled, a list of data areas being journaled and a list of integrated file system objects being journaled.
Example 3: More Complex Commands for *OUTFILE
WRKJRNA JRN(YOURLIB3/JRNLC) OUTPUT(*OUTFILE) OUTFILE(YOURLIB3/MYOUTFILE) DETAIL(*OUTPUT) WRKJRNA JRN(YOURLIB3/JRNLC) OUTPUT(*OUTFILE) OUTFILE(YOURLIB3/MYOUTFILE) DETAIL(*JRNFILE *JRNAP *JRNDTAQ *JRNDTAARA *JRNIFS)
These two commands create an output file named MYOUTFILE in library YOURLIB3 that contains information related to the journal JRNLC in library YOURLIB3. Specifically the information written to the output file includes a list of files being journaled, a list of access paths being journaled, a list of data queues being journaled, a list of data areas being journaled and a list of integrated file system objects being journaled.
Example 4: Selecting Specific Information to Print
WRKJRNA JRN(YOURLIB4/JRNLD) OUTPUT(*PRINT) DETAIL(*CURATR *JRNFILE)
This command prints information related to the journal JRNLD in library YOURLIB4. The information will be a subset of information about the journal. Specifically the information will be the journal attributes and a list of files being journaled.
Example 5: Selecting Specific Information to Output to a File
WRKJRNA JRN(YOURLIB5/JRNLE) OUTPUT(*OUTFILE) OUTFILE(YOURLIB5/MYOUTFILE) DETAIL(*JRNFILE *JRNDTAARA *IMPLICIT)
This command creates an output file named MYOUTFILE in library YOURLIB5 that contains information related to the journal JRNLE in library YOURLIB5. The information will be a subset of information about the journal. Specifically the information about journaled files, journaled data areas and objects being implicitly journaled to this journal.
Top |
*ESCAPE Messages
Top |