JOURNAL_CODE_INFO view
The JOURNAL_CODE_INFO view returns text descriptions for each journal code and each journal entry type.
Authorization: None required.
The following table describes the columns in the view. The system name is JRN_CODES. The schema is QSYS2.
| Column Name | System Column Name | Data Type | Description |
|---|---|---|---|
| JOURNAL_CODE | JRN_CODE | CHAR(1) | A journal code. |
| JOURNAL_CODE_DESCRIPTION | CODE_DESC | VARCHAR(100) | Descriptive text for the journal code. |
| JOURNAL_ENTRY_TYPE | ENTRY_TYPE | CHAR(2) Nullable
|
A journal entry type for the journal code. Contains the null value if no entry type is explicitly defined for this journal code. |
| JOURNAL_ENTRY_TYPE_DESCRIPTION | ENTRY_DESC | VARCHAR(200) Nullable
|
Descriptive text for the journal entry type. Contains the null value if no entry type is explicitly defined for this journal code. |
Examples
Expand the information returned by DISPLAY_JOURNAL to include descriptive text for the journal code and journal entry type for each row.
SELECT DJ.JOURNAL_CODE, JCI.JOURNAL_CODE_DESCRIPTION,
DJ.JOURNAL_ENTRY_TYPE, JCI.JOURNAL_ENTRY_TYPE_DESCRIPTION,
DJ.*
FROM TABLE (QSYS2.DISPLAY_JOURNAL('APPLIB', 'QSQJRN', STARTING_TIMESTAMP => CURRENT DATE - 5 DAYS)) DJ,
QSYS2.JOURNAL_CODE_INFO JCI
WHERE DJ.JOURNAL_CODE = JCI.JOURNAL_CODE AND
DJ.JOURNAL_ENTRY_TYPE = JCI.JOURNAL_ENTRY_TYPE;
