COMPAKTOR SELECT Statement


SELECT statement syntax

SELECT

DSN=filter|ALLDSN


,%FREE=nn


,DSORG=([DA][EF][PO][PS])


,EXTENTS=KEEP


,POS=BEGIN|END|KEEP|LVTOC|RVTOC|VTOC|ccccccchhhh


,RLSE=ALL|NO|ROUND|TRK


,VSRLSE=ALL|NO

SELECT statement

This statement is used to define data sets requiring special treatment by COMPAKTOR. SELECT DSN= is also used to define data sets that are members of a sequenced set (see SEQUENCE and ENDSEQ Statements).

Important

The SELECT statement specifies special processing options for selected data sets, but it does not imply that only those data sets are moved or released by COMPAKTOR. Only those data sets that are identified as unmovable or active by COMPAKTOR plus data sets identified by a “SELECT...,POS=KEEP” statement are bypassed by COMPAKTOR.

The available options are:

  • Prevent multi-extent merges
  • Control freeing of unused tracks
  • Position the selected data sets.

Up to 1000 SELECT statements may be input, but since each may select many data sets, an unlimited number of data sets may be affected.

SELECT statement operands

DSN=

filter

Specifies a fully-qualified data set name or a filter to be used for generic data set selection, as described in Generic-Data-Set-Name-Selection. All data sets on the volume matching this name or filter are affected by the options on this SELECT.

For VSAM data sets, you must specify component names. CPK does not recognize cluster names. For example:

DSN=USER1.JCL.CNTL

DSN=**LIST

DSN=PROD++.**.LIB*

Important

The DSG= operand documented in previous versions of COMPAKTOR is still accepted, but the DSN=operand with a generic data set name filter is the preferred way of selecting groups of data sets.

ALLDSN

Specifies that all of the data sets on the volume are affected by the options on this SELECT.

Either DSN= or ALLDSN must be specified on a SELECT statement. If SELECT DSN= statements specifying a fully-qualified data set name are present in the control statement input stream, they must precede all SELECT DSN=filter or ALLDSN statements.

If a data set is made unmovable by the COMPAKTOR Unmovable Table or the list of currently active data sets (DSNENQ=), and a SELECT statement specifying RLSE= or POS= (other than POS=KEEP) selects it, CPK abends. If you do not wish to abend, code SELTERR=NO on the CPK control statement. If you wish the data set to be moved, code OVERRIDE=YES on the CPK control statement. See Compacting Active Volumes for special considerations on compacting active volumes.

%FREE=

Specifies that CPK is to leave this percentage of the data set free after COMPAKTion. RLSE= and/or VSRLSE= must also be specified or else %FREE= is ignored. CPK only releases space on PS, PO, and VSAM data sets and never increases these data sets in size. For example, if a data set occupies 100 tracks of which 20 tracks are used, %FREE=50 leaves the final data set with 40 tracks. Values may be from zero (0) specifying that all of the unused space is to be freed, to 99 which says that 99% of the data set is to be left free.

Default: 0 unless %FREE= was coded on the CPK statement, or the %PSFREE=, %POFREE=, and/or %VSFREE= operands are coded on the CPK statement, depending on the type of data set selected.

DSORG=

Specifies that this control statement only applies to data sets with the specified data set organizations. Valid DSORG values are:.

DA

Specifies direct-access files.

EF

Specifies VSAM files.

PO

Specifies partitioned files (including PDSE).

PS

Specifies Physical Sequential (PS) files (including extended format (striped) sequential).

EXTENTS=

Specifies that all extents owned by the selected data sets are to be retained and not merged into a single extent, although they may be moved (use POS=KEEP to keep all the extents in their current locations).

If omitted, most multiple extent data sets are merged into a single extent, unless EXTENTS=KEEP is specified in the major statement.

POS=

If coded, specifies that positioning is requested for the selected data sets. Positioning is of two types: relative or absolute.

Relative positioning is specified by coding: VTOC, LVTOC, RVTOC, BEGIN, or END.

BEGIN

The data sets are placed as near the beginning of the DASD volume as possible.

END

The data sets are placed as close to the end of the DASD volume as possible.

KEEP

The data set is to retain its original position. If specified, RLSE=, VSRLSE=, and %FREE= cannot also be specified.

LVTOC

Specifies that the data sets are to be placed as close to the VTOC as possible, on the left side (lower numbered tracks) of it.

RVTOC

Specifies that the data sets are to be placed as close to the VTOC as possible, on the right side (higher numbered tracks) of it.

VTOC

Specifies that the data sets are to be placed as near the VTOC as possible, on either side of it.

Absolute positioning is specified by coding KEEP or an address (ccccccchhhh).

ccccccchhhh

Code a 5 to 11 digit decimal cylinder and head address, when you wish to specify an absolute position for the first track of the data set. The first 1 to 7 digits are the decimal cylinder number (at least one “c” value must be specified) and the last 4 are the decimal track number within that cylinder. Both cylinder and track addresses are relative to zero. POS=00000000 is invalid. CPK fails if this address causes the data set to overlap with an unmovable data set or another absolute positioned data set. Absolute positioning is not valid when DSN=filter or ALLDSN are coded; a fully-qualified data set name is required. A minimum of 5 digits must be specified.

If POS= is omitted, the position of the data set after COMPAKTion is determined by internal algorithms.

See COMPAKTOR Data Set Types for further considerations when positioning data sets. POS= must be omitted if the SELECT statement is part of a sequenced set, and it is invalid on TYPE=RLSE.

Important

We don't recommend positioning data sets when using TYPE=FASTCPK.

RLSE=

Specifies the action to be taken for the unused tracks in the selected data sets. This option is ignored if the data set is not sequential or partitioned.

ALL

For track-allocated data sets, all unused tracks are to be freed. For cylinder-allocated data sets, only the unused cylinders are freed.

NO

Unused tracks are kept.

ROUND

Only unused extents are to be freed.

TRK

All of the unused tracks are to be freed even if the data set is cylinder-allocated.

Important

If RLSE=TRK releases a cylinder-allocated data set past its cylinder boundary, CPK resets the cylinder-allocated indication in the affected extent descriptors in the DSCB. However, the secondary allocation type remains the same as before the release. (The secondary allocation type is shown in the SPACE ALLOC field in the CPK map). Some products, such as ISPF, test the secondary allocation type and may display a data set as occupying a number of whole cylinders when it really does not.

Default: The value of the PSRLSE= operand (if DSORG=PS) or PORLSE= operand (if DSORG=PO) of the SIMULATE or COMPAKT statement. If PSRLSE= and PORLSE= were omitted, then only data sets covered by a SELECT statement with the RLSE= operand has free space released. If PSRLSE= or PORLSE= is specified, then SELECT statements with RLSE= can be used to override them for selected data sets.

VSRLSE=

Specifies the action to be taken for the unused tracks in any VSAM components selected by this SELECT. It is ignored if the data set is not VSAM.

ALL

Components of VSAM data sets are released to the Control Area (CA) boundary closest to the HI-USED-RBA; additional CAs may be retained as free space for expansion if %FREE= or %VSFREE= is specified. Space is not released from the VVDS or multi-volume components, but it is released from catalogs if DSN= specifies the fully-qualified catalog component name and OVERRIDE=YES was also specified.

NO

Unused tracks are kept.

Default: NO, unless VSRLSE=ALL was specified on the major statement (except for catalog components, which is released ONLY if VSRLSE=ALL is specified on the SELECT).

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*