The Convert Record Lock 2 command builds an outfile of the record
locks held by a job. The outfile includes information about the
file, library, member, relative record number, and the status of the
lock (held or waiting). The file name created is RCDLCKP. The model
file used is TAADBJMP with a format name of RCDLCKR.
The API QDBRJBRL is used.
The command is public. Any user can convert the locks held by
another job.
To convert all locks held on a member, use CVTRCDLCK,
A typical command would be:
CVTRCDLCK2 JOB(xxx) OUTLIB(QTEMP)
The record locks held by the job would be written to the RCDLCKP file
in QTEMP.
Considerations
--------------
There are exceptions where the API may be unable to return the proper
information.
The API has a limit (as of V4R5) of 32,767 locks. A program may lock
more than this, but the API will make it appear that only 32,767
exist.
CVTRCDLCK2 escape messages you can monitor for
----------------------------------------------
TAA9894 No jobs exist for the qualified job name.
TAA9895 Duplicate job names exist.
TAA9896 The job is not active.
Escape messages from based on functions will be re-sent.
Command parameters *CMD
------------------
JOB The qualified name of the job to convert record
locks for. The default is * meaning the current
job. A specific job, user, and job number may be
entered.
OUTLIB The library in which the file RCDLCKP will be
placed. The default is *LIBL. If the RCDLCKP file
does not already exist, a library must be specified.
The model file used is TAADBJMP with a format name
of RCDLCKR.
OUTMBR The member of the RCDLCKP file to be used. The
default is RCDLCKP. If the member does not exist,
it is added.
REPLACE A *YES/*NO value for whether the member should be
cleared before writing records into it. The default
is *YES.
*NO may be specified to add records to the file.
Restrictions
------------
See the previous comments about exceptions in the Considerations
section.
Prerequisites
-------------
The following TAA Tools must be on your system:
CRTDUPPF Create duplicate physical file
EDTVAR Edit variable
RTVJOBSTS Retrieve job status
SNDCOMPMSG Send completion message
SNDESCMSG Send escape message
SNDSTSMSG Send status message
Implementation
--------------
None, the tool is ready to use.
Objects used by the tool
------------------------
Object Type Attribute Src member Src file
------ ---- --------- ---------- ----------
CVTRCDLCK2 *CMD TAADBJM QATTCMD
TAADBJMC *PGM CLP TAADBJMC QATTCL
TAADBJMR *PGM RPG TAADBJMR QATTRPG
TAADBJMP *FILE PF TAADBJMP QATTDDS
|