FMTQLFCMD FORMAT QUALIFIED COMMAND TAACMFM |
The Format Qualified Command command allows CL source to be formatted
so any qualified commands begin in position 14 of the source with the
command name. The / is placed in position 13 and the library name to
the left. This aligns the command names for easier reading of the
source. The command prompter formats a qualified name so the library
name begins in position 14.
FMTQLFCMD defaults to *CHECK to allow a review of what would happen
if *CHANGE was specified.
Any labels in the source followed by data will be flagged and are not
reformatted.
A specific, generic, or all members of a source file may be
processed. Only source members with a type of CLP, CLLE, or CLMOD
are processed. Other source types are bypassed (a count occurs).
You must have *CHANGE authority to the source file to use
OPTION(*CHANGE).
A typical command would be:
FMTQLFCMD FILE(QCLSRC) MBR(*ALL)
Because the default is OPTION(*CHECK), no changes would occur. A
listing would be displayed of each statement that had a qualified
command that would be changed. If a qualified command already begins
in position 14, the command is not listed. Both the old and
reformatted versions would be displayed.
If you want to make the proposed changes, you would specify:
FMTQLFCMD FILE(QCLSRC) MBR(*ALL) OPTION(*CHANGE)
The parameters for the command are shifted to begin in position 25.
This is the position used by the prompted for unqualified commands.
For example:
14 25
. .
TAATOOL/ADDDAT DAYS(3) TOVAR(&NEWDATE)
would become
14 25
. .
TAATOOL/ADDDAT DAYS(3) TOVAR(&NEWDATE)
FMTQLFCMD Restrictions
----------------------
** Only source files are supported up to a record length of 112
bytes.
** Only CLP, CLLE, and CLMOD source are processed.
** Valid source must exist.
** The command is not searched for if it begins after position
24.
** Any labels (a label ends with a ':') without a command are
ignored. Any labels followed by data will not be reformatted
and are flagged.
** Any comments prior to the command such as:
/* xxx */ QSYS/RTVJOBA ...
are lost when the reformatting occurs. Trailing comments are
retained.
FMTQLFCMD escape messages you can monitor for
---------------------------------------------
None. Escape messages from based on functions will be re-sent.
FMTQLFCMD Command parameters *CMD
----------------------------
SRCFILE The qualified name of the source file to be
formatted. The file name defaults to QCLSRC. The
library value defaults to *LIBL. A specific library
or *CURLIB may also be used.
MBR The member to be formatted.
The default is *ALL for all members.
A specific member or a generic member name may also
be specified.
OPTION The option to be used.
*CHECK is the default meaning a listing is produced
which describes the changes that would be made. No
changes occur.
*CHANGE may be specified to cause formatting changes
to the source if a statement has a command name that
does not begin in position 14. A listing is also
output.
OUTPUT How to output the results. * is the default to
display the spooled file if the command is entered
interactively. The spooled file is deleted after it
is displayed.
If the command is entered in batch or *PRINT is
specified, the spooled file is output and retained.
Restrictions
------------
See the previous section.
Prerequisites
-------------
The following TAA Tools must be on your system:
CHKDBFMBR Check data base file member
CHKGENERC Check generic
CHKOBJ3 Check object 3
CVTMBRLST2 Convert member list 2
EDTVAR Edit variable
HLRMVMSG HLL Remove message
RSNLSTMSG Resend last message
RTVSYSVAL3 Retrieve system value 3
SNDCOMPMSG Send completion message
SNDESCINF Send escape information
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
------ ---- --------- ---------- ----------
FMTQLFCMD *CMD TAACMFM QATTCMD
TAACMFMC *PGM CLP TAACMFMC QATTCL
TAACMFMR *PGM RPG TAACMFMC QATTRPG
|
Added to TAA Productivity tools January 15, 2011