The Display Empty Message File command displays one or more message
files that have no message IDs. A flag may be set if the message
file has not been used in the last n days. An option exists to list
all message files. DSPEMTMSGF can be helpful in cleaning up unused
message files.
You must have *ALLOBJ special authority to use a library value of
*ALL or *ALLUSR.
A typical command would be:
DSPEMTMSGF MSGF(*ALLUSR/*ALL) FLAGDAYS(100)
All message files in all user libraries that do not have any message
IDs would be listed.
Any message files that have not been used in the last 100 days would
be flagged. A message file is considered used if a command such as
SNDPGMMSG uses a message ID in the message file.
If the message file has never been used, the last change date of the
message file is used for a comparison.
When a message file is created, the system creates enough space for a
minimal number of message IDs. The API used internally does not
provide a count of the number of message IDs in the message file. To
determine if no message IDs exist, DSPEMTMSGF determines the size of
a message file. If it is less than 50,000 bytes, CVTMSGF is used to
determine if any messages exist. Because of this technique,
DSPEMTMSGF can be a slow running command.
DSPEMTMSGF escape messages you can monitor for
----------------------------------------------
None. Escape messages from based on functions will be re-sent.
DSPEMTMSGF Command parameters *CMD
-----------------------------
MSGF The qualified name of the message file to be
processed. A single message file, a generic name,
or the special value *ALL may be entered.
The library value defaults to *LIBL. A specific
library, *CURLIB, *USRLIBL, *ALL, or *ALLUSR may be
entered.
FLAGDAYS The number of days to flag the message file if it
has not been used. The default is 60 days. The
value must be in a range of 0-999. Using a value
provides a better indication of what is being used.
A message file is considered used if a command such
as SNDPGMMSG uses a message ID in the message file.
ALLMSGF Whether to list all message files regardless of
whether any message IDs exist.
*NO is the default to list only message files with
no message IDs.
If *NO is used and the message file has not been
used in the FLAGDAYS value, the message file will
not appear in the output. To list these types of
message files, specify ALLMSGF(*YES).
*YES may be specified to list all message files.
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
------------
You must have *ALLOBJ special authority to use a library value of
*ALL or *ALLUSR.
Prerequisites
-------------
The following TAA Tools must be on your system:
ADDDAT2 Add date 2
CHKALLOBJ Check *ALLOBJ special authority
CVTMSGF Convert message file
CVTOBJD4 Convert object description 4
EDTVAR Edit variable
RTVMSGFA Retrieve message file attributes
RTVSYSVAL3 Retrieve system value 3
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
------ ---- --------- ---------- ----------
DSPEMTMSGF *CMD TAAMSJY QATTCMD
TAAMSJYC *PGM CLP TAAMSJYC QATTCL
TAAMSJYR *PGM RPG TAAMSJYR QATTRPG
|