1 | Receiver variable | Output | Char(*) |
2 | Length of receiver variable | Input | Binary(4) |
3 | Format name | Input | Char(8) |
4 | Number of attributes to return | Input | Binary(4) |
5 | Key of attributes to be returned | Input | Array(*) of Binary(4) |
6 | Error code | I/O | Char(*) |
The Retrieve Current Attributes (QWCRTVCA) API retrieves job and thread attributes that apply to the thread in which this API is called. If a thread attribute exists, it is retrieved. If a thread attribute does not exist, the job attribute for the job in which this thread is running is retrieved.
None.
The variable that is used to return the thread attributes.
The length of the receiver variable.
The format of the attribute list to return. The possible format names follow:
RTVC0100 | Basic retrieve format |
RTVC0200 | Library list information |
RTVC0300 | ASP group information |
See RTVC0100 Format, RTVC0200 Format, and RTVC0300 Format for more information.
The number of attributes to return in the specified format.
The list of the attributes to be returned in the specified format. For a list of the valid key attributes, see Valid Key Attributes.
The structure in which to return error information. For the format of the structure, see Error Code Parameter.
The following table describes the order and format of the data that is returned in the receiver variable for format RTVC0100. See Valid Key Attributes for threadsafe information.
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
0 | 0 | BINARY(4) | Number of attributes returned |
These fields repeat, in the order listed, for each key requested. | BINARY(4) | Length of attribute information returned | |
BINARY(4) | Key | ||
CHAR(1) | Type of data | ||
CHAR(3) | Reserved | ||
BINARY(4) | Length of data | ||
CHAR(*) | Data | ||
CHAR(*) | Reserved |
Data. The data returned for the key field.
Key. The attribute returned. See Valid Key Attributes for the list of valid keys.
Length of attribute information returned. The total length of information returned for this attribute. This value is used to increment to the next entry in the list.
Length of data. The length of the data returned for the field.
Number of attributes returned. The number of attributes returned to the application.
Reserved. An ignored field.
Type of data. The type of output data. This field is provided to maintain the same format layout that is used in the Change Job (QWTCHGJB) API.
C | The output data is in character format. |
B | The output data is in binary format. |
The RTVC0200 format returns library list information. Retrieval of the
library list information is threadsafe. The format returns the actual length
instead of the total length because all libraries may not exist.
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
0 | 0 | BINARY(4) | Number of bytes returned |
4 | 4 | BINARY(4) | Number of bytes available |
8 | 8 | BINARY(4) | Number of libraries in SYSLIBL |
12 | C | BINARY(4) | Number of product libraries |
16 | 10 | BINARY(4) | Current library existence |
20 | 14 | BINARY(4) | Number of libraries in USRLIBL |
See note | See note | Array(*) of CHAR(11) | Library list (for each library in the list) |
Note: The decimal and hexadecimal offsets depend on the number of libraries you have in the various parts of your library lists and on keys requested. The data is left-justified and padded with blanks on the right. The array is sequential. See the CL Programming topic for the total number of libraries that can be returned to you. |
Current library existence. Whether the current library exists or not. This value will be zero if the current library was not requested.
0 | No current library exists. |
1 | A current library exists. |
Number of bytes available. All of the available bytes for use in your application.
The actual length depends on how many libraries are in the library list.
Number of bytes returned. The number of bytes returned to the user. This may be some but not all of the bytes available.
Number of libraries in SYSLIBL. The number of libraries in the system part of the thread's library list. This value will be zero if system libraries were not requested.
Number of libraries in USRLIBL. The number of libraries in the thread's user library list. This value will be zero if user libraries were not requested.
Number of product libraries. The number of product libraries found in the thread's library list. This value will be zero if product libraries were not requested.
Library list (for each library in the list). The list of all libraries requested. A blank is in the last position of each name. The number of libraries in the list will depend on the keys requested and the actual number of libraries in each portion of the library list. The order of the library list is:
The RTVC0300 format returns auxiliary storage pool (ASP) group information. Retrieval of the ASP group information is threadsafe.
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
0 | 0 | BINARY(4) | Number of bytes returned |
4 | 4 | BINARY(4) | Number of bytes available |
8 | 8 | BINARY(4) | Offset to ASP group information |
12 | C | BINARY(4) | Number of entries in ASP group information |
16 | 10 | BINARY(4) | Length of one ASP group information entry |
See note | See note | Array(*) of CHAR(*) | ASP group information entry (See Format of ASP Group Information Entry for more information.) |
Note: This field repeats for each ASP group information entry. For additional information, see the Control Language (CL) information for the Set ASP Group (SETASPGRP) command. |
ASP group information entry. The auxiliary storage pool (ASP) group information requested. This does not include the system ASP or the basic user ASP.
Length of one ASP group information entry. The length of one ASP group information entry.
Number of ASP group information entries The number of ASP group information entries being returned.
Number of bytes available. The number of available bytes for use by your application.
Number of bytes returned. The number of bytes returned to the user. This may be some but not all of the bytes available.
Offset to ASP group information The offset in characters (bytes) from the beginning of the receiver to the first ASP group information entry.
The ASP group information entry describes the data that is returned for each ASP group of the RTVC0300 format.
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
These fields repeat for each entry returned in the list. | CHAR(10) | ASP group name | |
CHAR(*) | Reserved |
ASP group name The name of the ASP group. This is the name of the primary ASP device in an ASP group.
The following table contains a list of the valid keys for format RTVC0100. In addition, the table indicates whether the attributes are threadsafe. See Key Field Descriptions for the descriptions of the valid key attributes.
Key | Type | Description | Threadsafe (See Note) |
---|---|---|---|
0102 | CHAR(1) | Allow multiple threads | Yes |
0201 | CHAR(10) | Break message handling | Yes |
0301 | CHAR(1) | Cancel key | Yes |
0302 | BINARY(4) | Coded character set ID | Yes |
0303 | CHAR(2) | Country or region ID | Yes |
0305 | CHAR(10) | Current user profile | Yes |
0307 | BINARY(4) | Current system pool identifier | Yes |
0311 | CHAR(10) | Character identifier control | Yes |
0401 | CHAR(13) | Date and time job became active | Yes |
0402 | CHAR(13) | Date and time job entered system | Yes |
0403 | CHAR(8) | Date and time job was scheduled to run | Yes |
0405 | CHAR(4) | Date format | Yes |
0406 | CHAR(1) | Date separator | Yes |
0407 | CHAR(1) | DBCS-capable | Yes |
0408 | CHAR(10) | DDM conversation handling | Yes |
0409 | BINARY(4) | Default wait | Yes |
0410 | CHAR(13) | Device recovery action | Yes |
0412 | BINARY(4) | Default coded character set identifier | Yes |
0413 | CHAR(1) | Decimal format | Yes |
0501 | BINARY(4) | End severity | Yes |
0502 | CHAR(1) | End status | Yes |
0503 | CHAR(1) | Exit key | Yes |
0702 | CHAR(10) | Group profile name | Yes |
0703 | CHAR(150) | Group profile name - supplemental | Yes |
0901 | CHAR(10) | Inquiry message reply | Yes |
0902 | CHAR(16) | Internal job ID | Yes |
0903 | CHAR(1) | Initial thread | Yes |
1001 | CHAR(15) | Job accounting code | Yes |
1002 | CHAR(7) | Job date | Yes |
1004 | CHAR(20) | Job queue name - qualified | Yes |
1005 | CHAR(2) | Job queue priority | Yes |
1006 | CHAR(8) | Job switches | Yes |
1007 | CHAR(10) | Job message queue full action | Yes |
1008 | BINARY(4) | Job message queue maximum size | Yes |
1009 | CHAR(26) | Job name | Yes |
1010 | CHAR(1) | Job type | Yes |
1011 | CHAR(1) | Job subtype | Yes |
1017 | CHAR(8) | Job local time | Yes |
1018 | CHAR(10) | Job log output | Yes |
1201 | CHAR(3) | Language ID | Yes |
1202 | CHAR(1) | Logging level | Yes |
1203 | CHAR(10) | Logging of CL programs | Yes |
1204 | BINARY(4) | Logging severity | Yes |
1205 | CHAR(10) | Logging text | Yes |
1304 | BINARY(4) | Maximum threads | Yes |
1501 | CHAR(20) | Output queue name - qualified | Yes |
1502 | CHAR(2) | Output queue priority | Yes |
1601 | CHAR(10) | Print key format | Yes |
1602 | CHAR(30) | Print text | Yes |
1603 | CHAR(10) | Printer device name | Yes |
1604 | CHAR(10) | Purge | Yes |
1802 | BINARY(4) | Run priority | Yes |
1901 | CHAR(20) | Sort sequence table - qualified | Yes |
1902 | CHAR(10) | Status message handling | Yes |
1904 | CHAR(26) | Submitter's job name - qualified | Yes |
1905 | CHAR(20) | Submitter's message queue name - qualified | Yes |
1907 | BINARY(4) | System pool identifier | Yes |
1982 | CHAR(10) | Spooled file action | Yes |
2001 | CHAR(1) | Time separator | Yes |
2002 | BINARY(4) | Time slice | Yes |
2003 | CHAR(10) | Time-slice end pool | Yes |
2008 | BINARY(4) | Thread count | Yes |
2020 | CHAR(10) | Time zone current abbreviated name | Yes |
2021 | CHAR(50) | Time zone current full name | Yes |
2022 | CHAR(7) | Time zone current message identifier | Yes |
2023 | BINARY(4) | Time zone current offset | Yes |
2024 | CHAR(10) | Time zone description name | Yes |
2025 | CHAR(20) | Time zone message file name - qualified | Yes |
2026 | CHAR(1) | Time zone Daylight Saving Time indicator | Yes |
Note:If this value is blank, the attribute is not threadsafe. |
The following table contains a list of the valid keys for format RTVC0200. In addition, the table indicates whether the attributes are threadsafe. See Key Field Descriptions for the descriptions of the valid key attributes.
Key | Type | Description | Threadsafe (See Note) |
---|---|---|---|
0310 | CHAR(11) | Current library | Yes |
1660 | Array(*) of CHAR(11) | Product libraries | Yes |
1980 | Array(*) of CHAR(11) | System library list | Yes |
2110 | Array(*) of CHAR(11) | User library list | Yes |
2702 | Array(*) of CHAR(11) | All portions of the library list for format RTVC0200 | Yes |
Note: If this value is blank, the attribute is not threadsafe. |
The following table contains a list of the valid keys for format RTVC0300. In addition, the table indicates whether the attributes are threadsafe. See Key Field Descriptions for the descriptions of the valid key attributes.
Key | Type | Description | Threadsafe (See Note) |
---|---|---|---|
0104 | CHAR(*) | ASP group information | Yes |
Most field descriptions for this API are in Work Management API Attribute Descriptions (WMAttrDesc), except the following:
All portions of the library list for format RTVC0200. All portions of the library list will be returned.
Current system pool identifier. The identifier of the system-related pool from which this thread's main storage currently is being allocated. These identifiers are not the same as those specified in the subsystem description, but are the same as the system pool identifiers shown on the system status display. If a thread reaches the end of its time slice, the pool this thread is running in can be switched based on the job's time-slice end pool value. The current system pool identifier returned by this API will be the actual pool in which the thread currently is running.
Run priority. The priority at which this thread currently is running, relative to other threads on the system. The run priority ranges from 0 (highest priority) to 99 (lowest priority). The value may never be higher than the run priority for the job in which this thread is running. Since this API is intended for retrieving the current value of an attribute, the run priority of the thread is returned, even though the 1802 key represents the run priority of the job on other interfaces. To obtain the run priority of the job, use the 1802 key on the Retrieve Thread Attributes (QWTRTVTA) API.
Message ID | Error Message Text |
---|---|
CPF1866 E | Value &1 for number of fields to return not valid. |
CPF1867 E | Value &1 in list not valid. |
CPF3C1D E | Length specified in parameter &1 not valid. |
CPF3C21 E | Format name &1 is not valid. |
CPF3C36 E | Number of parameters, &1, entered for this API was not valid. |
CPF3C90 E | Literal value cannot be changed. |
CPF3CF1 E | Error code parameter not valid. |
CPF3CF2 E | Error(s) occurred during running of &1 API. |
CPF9872 E | Program or service program &1 in library &2 ended. Reason code &3. |
Top | Work Management APIs | APIs by category |