Selecting objects with the SAVLIB command

With the SAVLIB command, you can select libraries and objects to include or exclude from the save operation.

Parameter Description
Library (LIB) Allows you to select libraries to include in the save operation. You can specify a special value or up to 300 single or generic library names.1
Omit object (OMITOBJ) Allows you to select objects to exclude from the save operation. You can specify up to 300 values. You can specify generic object and library names.1
Omit library (OMITLIB) Allows you to select libraries to exclude from the save operation. You can specify up to 300 single or generic library names.1
Select (SELECT) Allows you to select objects, object types, object attributes, and file members to include or omit. You can use this parameter to refine your selections for the parameters listed above.

1 Use the Command user space (CMDUSRSPC) parameter on the save commands to specify up to 32767 names for the parameters.

Here is an example of omitting a group of libraries from a SAVLIB operation:

SAVLIB LIB(*ALLUSR) OMITLIB(TEMP*)

An example of using the OMITLIB parameter along with generic library naming appears as: SAVLIB LIB(T*) OMITLIB(TEMP). The system saves all libraries that begin with the letter 'T' except for the library that is named TEMP.

You can also use the OMITLIB parameter with generic naming while performing concurrent save operations to different media devices:
SAVLIB LIB(*ALLUSR) DEV(first-media-device) OMITLIB(A* B* $* #* @*...L*)
SAVLIB LIB(*ALLUSR) DEV(second-media-device) OMITLIB(M* N* ...Z*)