Previous Topic: SCAN CATALOGS CommandNext Topic: Processing Considerations


FIND Command

The FIND command is used to specify a data set name or pattern to be processed. The function of the FIND command is to improve the performance of CA Disk when only one or a small subset of data sets is to be processed. Rather than scanning an entire catalog (as happens with the SCAN command), CA Disk will issue one superlocate for the data set name or pattern specified. Catalog management returns all data set name(s) matching the data set name specified in one inquiry, thereby reducing catalog management overhead for the job.

SELECT and EXCLUDE commands can be used with the FIND command, although this would be useful only if a pattern is specified for the data set name. If any SELECT and/or EXCLUDE commands are used, they must follow the FIND command and precede the action command(s) for the specified data set name/pattern. You can use this command in the same job stream as the SCAN command, although it would be duplicating effort if the data set name specified on the FIND command would otherwise be processed as a result of the SCAN command.

When should you use the FIND command? Any time that you are interested in processing one cataloged data set or cluster, a few cataloged data sets or clusters, or a group of cataloged data sets or clusters that share the same high level qualifier or qualifiers.

As an example of how the FIND and SCAN commands can accomplish the same objective, look at the following:

SCAN REALVOLS
SELECT DSNAMES=LABS.TJP./
ARCHIVE
SCAN CATALOGS=ICF.TESTCAT
SELECT DSNAMES=LABS.TJP./
ARCHIVE
FIND DSNAMES=LABS.TJP./
ARCHIVE

In this instance, the FIND command would probably be a better choice because much of the overhead associated with scanning VTOCs or a VSAM catalog is eliminated. However, a SCAN command with the SELECT command will accomplish the same objective.

The FIND command searches ICF, VSAM and OS CVOL catalogs for entries. One disadvantage of using the FIND command is that catalog management will search only one catalog to find the data set name or pattern that you specify. In some situations, the catalog name should be specified on the FIND command so that catalog management can locate the data set. Two of these situations are: when the first-level node of the data set does not have an alias pointer in the master catalog, and when the data set is in the wrong catalog. Note that if the data sets you are attempting to process are uncataloged, you must change your command and use SCAN REALVOLS.