COZZI - Save Spool File (SAVSPLF)

Where allowed to run: All environments (*ALL)
Threadsafe: No
Parameters
Examples
Error messages

The COZZI - Save Spool File (SAVSPLF) command saves the contents of a SPOOL file to a database file. The SPOOL file can be restored by the Restore SPOOL File (RSTSPLF) command. All SPOOL File Attributes are saved with the SPOOL file data, so the restored SPOOL File will be nearly identical to the original--some attributes are always recreated when restoring a SPOOL file using these commands, such as creation date/time.

Top

Parameters

Keyword Description Choices Notes
SPLFNAME SPOOL file name Generic name, name, *ALL, *LAST Required, Positional 1
JOB Job name Single values: *, *CURRENT, *ALL
Other values: Qualified job name
Optional, Positional 2
Qualifier 1: Job name Name
Qualifier 2: User Name
Qualifier 3: Number 000000-999999
SPLNBR SPOOL file number 1-999999, *ONLY, *LAST, *ANY, *ALL Optional
OUTQ Output Queue filter Single values: *ALL
Other values (up to 300 repetitions): Qualified object name
Optional
Qualifier 1: Output Queue filter Name
Qualifier 2: Library Name, *LIBL
USER User profile filter Single values: *JOB, *ALL
Other values (up to 300 repetitions): Name, *CURRENT
Optional
USRDTA User data filter Character value, *ALL, *BLANK Optional
FORM Forms type filter Character value, *ALL, *STD Optional
CRTDATE SPOOL File Create-Time Filter Single values: *ALL
Other values: Element list
Optional
Element 1: Earliest Date to include Date, *CURRENT, *AVAIL
Element 2: Earliest Time to include Time, *AVAIL, *BEGIN
Element 3: Ending Date to include Date, *CURRENT, *AVAIL
Element 4: Ending Time to include Time, *AVAIL, *END, *CURRENT
ARCHIVE SPOOL Archive file Qualified object name Optional
Qualifier 1: SPOOL Archive file Name, USRSAVSPLF
Qualifier 2: Library Name, *LIBL, *CURLIB
Top

SPOOL file name (SPLFNAME)

Specify the name of the SPOOL File to be saved.

This is a required parameter.

*ALL
All SPOOL files that match the various "filter" parameters are saved.
generic-SPLF-name
Specify a generic SPOOL File name.
name
Specify a SPOOL File name.
Top

Job name (JOB)

Specify the job name that is searched for the SPOOL file named on the SPLFNAME parameter.

Single values

*
The current job (the job running the SAVSPLF command) is searched for the SPOOL File name specified on the SPLFNAME parameter.
*CURRENT
Same as JOB(*)
*ALL
All jobs are searched for SPOOL File whose name matches the SPLFNAME parameter. Be careful when selecting this option as it can produce a large number of entries in the SPOOL File Archive.

Qualifier 1: Job name

name
Specify the 3-part qualified job name that is searched for the SPOOL File specified on the SPLFNAME parameter.
Top

SPOOL file number (SPLNBR)

Specify the SPOOL File number of the SPOOL File name. If a SPOOL File Name (SPLFNAME parameter) appears more than once, the SPLNBR parameter identifies which opne of the multiple SPOOL files should be saved.

*ONLY
Use this when your certain the SPOOL File is the only one in the job with the unique SPOOL File name. (No, I don't get why we would ever use this over *LAST, either.)
*LAST
The SPOOL File with the highest number that matches the SPOOL File name specified on the SPLFNAME parameter is selected.
*ANY or *ALL
Use *ANY or *ALL interchangeably. Specify either of these values when you don't care about the SPOOL File number.
1-999999
Specify the specific SPLNBR (SPOOL File Number) assigned to the SPOOL File you want to save.
Top

Output Queue filter (OUTQ)

Specify the name of the OUTQ in which to look for the SPOOL File name. Up to 300 qualified OUTQ names may be used to filter the search.

Single values

*ALL
Use this (the default) when all OUTQ should be searched.

Output Queue Filter...

name
Specify up to 300 qualified output queue names. Only these output queues are searched for SPOOL Files that match the name specified on the SPLFNAME parameter.
Top

User profile filter (USER)

Specify one or more User Profiles who own the SPOOL File. Only uses whose user profile name appears on this list are searched for the SPOOL File Name specified on the SPLFNAME parameter.

Single values

*JOB
When *JOB is specified the user profile associated with the job specified on the JOB parameter is used. Note that if multiple jobs are identified, such as when JOB(*ALL) is specified, the user profile assigned to each job is used to search. Meaning if user BOB owns SPLFNAME(REPORTS) in job X, and CAROLE owns SPLFNAME(REPORTS) in job y, the user BOB is used for job X and user CAROLE is used for job y. Therefore both SPOOL Files will be saved.
*ALL
All users are included in the search for the SPOOL File.

Other values (up to 300 repetitions)

*CURRENT
The current user profile (the one running the SAVSPLF command) is used to filter the SPOOL File names.
name
Specify the name of up to 300 user profiles to use to filter the list of SPOOL Files specified on the SPLFNAME parameter.
Top

User data filter (USRDTA)

Specify a filter for the User Data of the SPOOL Files to save.

*ALL
User Data is not used to filter the SPOOL Files.
*BLANK
The User Data of the SPOOL File must be blank (empty) to be included.
character-value
Specify up to 10-characters of User Data to filter the SPOOL File names. Only SPOOL Files that have matching User Data are included.
Top

Forms type filter (FORM)

Specify a filter for the FORM of the SPOOL Files to save.

*ALL
All FORM Types are included.
*STD
Only SPOOL Files with *STD form type are included.
character-value
Specify the form type to include in the filter.
Top
Top

SPOOL Archive file (ARCHIVE)

Specify the name of the database file that is used as the SPOOL File Archive. If the file does not exist, it is created using the COZSAVSPLF DB2 definition.

SPOOL Archive file

USRSAVSPLF
The SPOOL File Archive is named USRSAVSPLF. This is the default name.
name
Specify the name of the database file where the SPOOL Files are saved.
Top

Examples

None
Top

Error messages

Unknown
Top