Start of change

ACTIVATION_GROUP_INFO table function

The ACTIVATION_GROUP_INFO table function returns all the activation groups that are associated with a job and their attributes.

This information is similar to what can be accessed through the Display Job (DSPJOB) CL command and the Open List of Activation Group Attributes (QWVOLAGP) API.

Authorization: None required for a job where the caller's user profile is the same as the job user identity of the job for which the information is being returned.

Otherwise, the caller must have *JOBCTL special authority.

Read syntax diagramSkip visual syntax diagramACTIVATION_GROUP_INFO( JOB_NAME => job-name,INTERNAL_JOB_ID => internal-job-id,IGNORE_ERRORS => ignore-errors)

The schema is QSYS2.

job-name
A character string that identifies the qualified name of a job in the form job-number/job-user/job-name.
The special value of '*' indicates the current job.
If job-name is provided, internal-job-id must be omitted.
internal-job-id
A binary string that contains an internal job identifier. This can be passed for quicker performance. This value is returned in the INTERNAL_JOB_ID column by the ACTIVE_JOB_INFO table function.
If internal-job-id is provided, job-name must be omitted.
ignore-errors
A character string that identifies what to do when an error is encountered.
NO
An error is returned.
YES
A warning is returned.
No row is returned when an error is encountered. This is the default.

The result of the function is a table containing one row for every activation group for the job with the format shown in the following table. All columns are nullable.

Table 1. ACTIVATION_GROUP_INFO table function
Column Name Data Type Description
ACTIVATION_GROUP_NAME VARCHAR(10) The name of the activation group. Can contain one of the following special values:
*DFTACTGRP
The activation group is one of the default activation groups.
*NEW
The activation group is *NEW.
ACTIVATION_GROUP_NUMBER DECIMAL(20,0) The activation group number.
STORAGE_MODEL VARCHAR(10) The storage model of the activation group.
*SNGLVL
The activation group is single level store.
*TERASPACE
The activation group is teraspace.
STATE VARCHAR(6) The state of the activation group.
SYSTEM
The activation group is in system state.
USER
The activation group is in user state.
NUMBER_OF_ACTIVATIONS INTEGER The total number of program activations in this activation group.
PROGRAM_LIBRARY VARCHAR(10) The name of the library that contains the program that caused this activation group to be created.

Contains the null value when PROGRAM is null.

PROGRAM VARCHAR(10) The name of the program that caused this activation group to be created.

Contains the null value when the activation group is one of the default activation groups or if the program no longer exists in the system.

PROGRAM_TYPE VARCHAR(6) The type of program that caused this activation group to be created.
JAVA
A Java™ program.
PGM
A program.
SRVPGM
A service program.

Contains the null value when PROGRAM is null.

SHARED_ACTIVATION_GROUP VARCHAR(3) Whether the activation group is shared. A shared activation group is an activation group that belongs to more than one job at the same time.
NO
The activation group is not shared with other jobs.
YES
The activation group is shared with other jobs.
IN_USE VARCHAR(3) Whether the activation group is eligible to be reclaimed. An activation group can be reclaimed using the Reclaim Activation Group (RCLACTGRP) command.
NO
The activation group is not in use and is eligible to be reclaimed.
YES
The activation group is in use and cannot be reclaimed.
STATIC_STORAGE_SIZE DECIMAL(20,0) The total amount of static storage allocated to the activation group, in bytes. If the size exceeds 4,294,967,295 bytes, 4,294,967,295 will be returned.
NUMBER_OF_HEAPS INTEGER The total number of heaps that are allocated by this activation group.
HEAP_STORAGE_SIZE DECIMAL(20,0) The total amount of heap storage that is allocated to the activation group, in bytes. If the size exceeds 4,294,967,295 bytes, 4,294,967,295 will be returned.

Example

  • List the activation group information for the current job.
    SELECT * FROM TABLE(QSYS2.ACTIVATION_GROUP_INFO('*'));
    
  • List the activation group information for a job based on its internal job identifier.
    SELECT * FROM TABLE(QSYS2.ACTIVATION_GROUP_INFO(
                        INTERNAL_JOB_ID => BX'00D10003007E3F00A784A7CBD6E89001'));
    
End of change