WRKSRVPGM (Work with Service Programs)
WRKSRVPGM Command syntax diagram
Purpose
The Work with Service Programs (WRKSRVPGM) command allows you to display and work with a list of service programs from one or more libraries.
Restrictions
- Only the libraries to which you have *USE authority are searched.
- Only the service programs to which you have authority are shown on the display.
- To perform operations on the service programs, have *USE authority to the command used by the operation and the appropriate authority to the service programs on which the operation is to be performed.
Required Parameters
- SRVPGM
- Specifies the search process for service programs to be placed in the list. All service programs with names corresponding to the specified parameter value, and for which the user has authority, are shown.
The name of the service program list can be qualified by one of the following library values:
*LIBL: All libraries in the job's library list are searched. All objects in these libraries with the specified object name are shown.
*CURLIB: The current library for the job is searched. If no library is specified as the current library for the job, the QGPL library is used.
*USRLIBL: Only the libraries in the user portion of the job's library list are searched.
*ALL: All libraries in the system, including QSYS, are searched.
library-name: Specify the name of the library to be searched.
*ALL: All service programs in the libraries identified in the library qualifier are shown.
service-program-name: Specify the name of the service program shown.
generic*-service-program-name: Specify the generic name of the service program being shown. A generic name is a character string of one or more characters followed by an asterisk (*); for example, ABC*. If a generic name is specified, then all service programs with names that begin with the generic name, and for which the user has authority, are shown. If an asterisk is not included with the generic (prefix) name, the system assumes it to be the complete service program name.
Example for WRKSRVPGM
WRKSRVPGM SRVPGM(COMPLETE)This command displays a list of service programs named COMPLETE.
Error messages for WRKSRVPGM
*ESCAPE Messages
- CPF9809
- Library &1 cannot be accessed.
- CPF9820
- Not authorized to use library &1.