Start of change

PROGRAM_EXPORT_IMPORT_INFO view

The PROGRAM_EXPORT_IMPORT_INFO view returns the data and procedure that are exported or imported for an ILE program or service program.

The values returned for the columns in the view are closely related to the values returned for *PROCEXP, *DTAEXP, *ACTGRPEXP, and *ACTGRPIMP detail on the DSPSRVPGM (Display Service Program) CL command and *ACTGRPEXP and *ACTGRPIMP detail on the DSPPGM (Display Program) CL command. It is similar to the information returned by the List Service Program Information (QBNLSPGM) and List Program Information (QBNLPGMI) APIs.

Authorization: The caller must have:
  • *EXECUTE authority to the library containing the program or service program, and
  • *READ authority to the program or service program.

The following table describes the columns in the view. The system name is EXPIMP_INF. The schema is QSYS2.

Table 1. PROGRAM_EXPORT_IMPORT_INFO view
Column Name System Column Name Data Type Description
PROGRAM_LIBRARY PGM_LIB VARCHAR(10) The library containing the program or service program.
PROGRAM_NAME PGM_NAME VARCHAR(10) The program or service program to which this export or import applies.
OBJECT_TYPE OBJ_TYPE VARCHAR(7) Object type for PROGRAM_NAME.
*PGM
A program.
*SRVPGM
A service program.
SYMBOL_NAME NAME VARGRAPHIC(8192)
CCSID 1200
The name of a procedure or data export or import.
SYMBOL_USAGE USAGE VARCHAR(10) The type of export or import.
*ACTGRPEXP
The data export to the activation group.
*ACTGRPIMP
A data import that is resolved by a weak export that had been exported to the activation group.
*DTAEXP
A data item exported from this service program.
*PROCEXP
A procedure exported from this service program.
ARGUMENT_OPTIMIZATION ARGOPT VARCHAR(4)
Nullable
Whether the service program procedure export uses argument optimization.
*NO
The procedure export does not use argument optimization.
*YES
The procedure export uses argument optimization.

Contains the null value if SYMBOL_USAGE is not *PROCEXP.

DATA_ITEM_SIZE DATA_SIZE INTEGER
Nullable
The size of the data item export, in bytes.

Contains the null value if SYMBOL_USAGE is not *ACTGRPEXP.

Example

  • Show all the procedure exports for service program APP_PGM1 in APPLIB.
    SELECT *
      FROM QSYS2.PROGRAM_EXPORT_IMPORT_INFO 
      WHERE PROGRAM_LIBRARY = 'APPLIB' AND 
            PROGRAM_NAME    = 'APP_PGM1' AND
            OBJECT_TYPE     = '*SRVPGM' AND
            SYMBOL_USAGE    = '*PROCEXP';
  • Find the service program in QSYS that exports printf to joblog (Qp0zLprintf).
    SELECT *
     FROM QSYS2.PROGRAM_EXPORT_IMPORT_INFO 
     WHERE PROGRAM_LIBRARY = 'QSYS' AND SYMBOL_NAME = 'Qp0zLprintf';
    
End of change