The Create Target Release command assists in creating or changing
objects to be saved for a named release. A specific or generic
object is named or all objects in a library. Either a new library
must be named and must not exist (it is created by CRTTGTRLS) or the
objects in the same library will be created for the named release.
The TAA Tool RPLOBJ is used to recreate program and module objects
and produces a listing of the results.
You must have *ALLOBJ special authority to use CRTTGTRLS.
A typical command would be:
CRTTGTRLS FROMLIB(ABC) TOLIB(ABC2) TGTRLS(*PRV)
TOLIBTEXT(*FROMLIB)
The ABC2 library must not exist and would be created. The text
description would be the same as the From library. All objects in
ABC would be duplicated to ABC2 including any data. All objects that
allow a TGTRLS value (*MODULE and *PGM) would be re-created using the
source member that created each object. Any objects that are
required for a create (commands, data areas, /COPY objects, etc) must
exist on the library list when the command runs. *MODULES are
created first. The target release would be specified as *PRV.
A listing would exist of the results from the sub tool RPLOBJ. Only
the *MODULE and *PGM objects would be listed. If some objects did
not create successfully, they must be handled manually.
RPLOBJ uses the source file/library/member information from the
object to re-create the object. Therefore, the source does not have
to be in the same library as the object being created.
The library is then ready to be saved to the previous release and
sent to the another system.
*FILE and *CMD object types which are created from source are
duplicated by CRTDUPOBJ and not re-created because they do not have a
TGTRLS parameter.
Another typical example, would be:
CRTTGTRLS FROMLIB(ABC) TOLIB(*FROMLIB)
TGTRLS(*PRV)
The program and module objects in library ABC would be re-created for
the previous release.
Reasons for failures to recreate
--------------------------------
There are several reasons that modules and programs could not be
re-created such as:
** The source used to create the object does not exist where the
object was created from.
** Objects that are required for a create (commands, data areas,
/COPY objects, etc) must exist on the library list when the
command runs.
** The object does not contain the source information. This is
typical of multi-module programs where the modules exist in a
library other than the From library. If the modules exist in
the From library along with the source for them, both the
modules and the program would normally be re-created properly.
CRTTGTRLS escape messages you can monitor for
---------------------------------------------
None. Escape messages from based on functions will be re-sent.
CRTTGTRLS Command parameters *CMD
----------------------------
FROMLIB The From library containing the objects that will be
duplicated.
TOLIB The TO library where the new objects will be
created. If a specific library is named (it cannot
be the same as the From library), the library must
not exist and will be created by CRTTGTRLS.
The special value *FROMLIB may be used to re-create
the module and program objects in the From library.
When TOLIB(*FROMLIB) is used, the defaults must be
used for SRCLIB and TOLIBTEXT. Both values are
ignored.
OBJ The object or generic object name to create. *ALL
is the default for all *PGM and *MODULE objects in
the From library.
TGTRLS The target release of the programs that will be
replaced. This is the same value as used on several
CRT program commands and is passed thru to the CRT
command.
*PRV is the default. Use the command prompter to
see the specific release names that may also be
entered.
GENLVL The generation severity level specifies the
diagnostic-message severity level at which creation
of a program or module stops.
*DFT is the default which is passed thru to the
CRTRPGxxx or CRTCBLxxx commands to use the default
supplied by the compilers.
A specific value between 1 and 50 may be entered,
but see the specific command for a narrower range.
SRCLIB The source library used for the create of objects
created from source.
*FROMOBJ is the default meaning the source library
used to create the object as found in the object
description.
*TOLIB may be specified to mean the source library
of the To Library. This assumes that the From
Library contains the source files used to create the
objects. This causes a change to the object
descriptions of the From library *MODULE and *PGM
objects so that the source library reflects the To
library. This change occurs before the *MODULE and
*PGM objects are re-created.
Assume the following: 1) You have library ABC which
should be sent to another system which is at a
previous release. 2) The ABC library also contains
the source files that were used to create the
objects. 3) You want to use CRTTGTRLS to create a
new library ABC2 which would contain the ABC objects
and can be saved to a previous release. 4) You want
to restore the ABC2 library on the other system and
use the original library name of ABC (RSTLIB
SAVLIB(ABC2) RSTLIB(ABC)). In this case, you want
to take the default of SRCLIB(*FROMOBJ) so that when
the restore occurs, the objects will appear to be
created from the source files that exist in ABC on
the system where the restore occurred,
TOLIBTEXT The text description of the new To library.
*FROMLIB is the default meaning to use the same text
description as exists for the From library.
Restrictions
------------
You must have *ALLOBJ special authority to use CRTTGTRLS.
The source must exist in the same location where the *PGM and *MODULE
objects were created from.
Objects that are required for a create (commands, data areas, /COPY
objects, etc) must exist on the library list when the command runs.
Prerequisites
-------------
The following TAA Tools must be on your system:
CHKALLOBJ Check *ALLOBJ special authority
EDTVAR Edit variable
RPLOBJ Replace object
RTVPRVRLS Retrieve previous release
SNDCOMPMSG Send completion message
SNDESCINF Send escape information
SNDESCMSG Send escape message
Implementation
--------------
None, the tool is ready to use.
Objects used by the tool
------------------------
Object Type Attribute Src member Src file
------ ---- --------- ---------- ----------
CRTTGTRLS *CMD TAALIDK QATTCMD
TAALIDKC *PGM CLP TAALIDKC QATTCL
TAALIDKC2 *PGM CLP TAALIDKC2 QATTCL
|