Display Message Description (DSPMSGD)

Where allowed to run: All environments (*ALL)
Threadsafe: No
Parameters
Examples
Error messages

The Display Message Description (DSPMSGD) command shows detailed information about the messages in a message file. The descriptions of specific messages, or a range of messages in one message file, can be specified by their identifiers, or all messages in one message file can be specified.

Top

Parameters

Keyword Description Choices Notes
RANGE Range of message identifiers Single values: *ALL
Other values: Element list
Optional, Positional 1
Element 1: Lower value Name, *FIRST
Element 2: Upper value Name, *ONLY, *LAST
MSGF Message file Qualified object name Optional, Positional 2
Qualifier 1: Message file Name, QCPFMSG
Qualifier 2: Library Name, *LIBL, *CURLIB, *USRLIBL
DETAIL Detail *BASIC, *FULL Optional
FMTTXT Format message text *YES, *NO Optional
OUTPUT Output *, *PRINT Optional
Top

Range of message identifiers (RANGE)

Specifies the range of message identifiers in the specified message file for which message descriptions are displayed or printed. All message descriptions in the message file specified for the Message file (MSGF) parameter can be displayed or printed by specifying *ALL on this parameter.

If the starting message identifier is not specified, the message descriptions begin with the first message in the specified message file.

Note: The ending message identifier is ignored when DETAIL(*BASIC) is specified with OUTPUT(*) and the list of message identifiers is displayed interactively.

Single values

*ALL
All message descriptions in the message file specified are displayed or printed. This value can only be specified in the first element of this parameter.

Element 1: Lower value

The first element of this parameter, called the starting message identifier, specifies the message identifier of the first message description to display or print.

*FIRST
The first message in the file specified for the Message file (MSGF) parameter is the first message whose description is displayed or printed.
lower-value
Specify the 7-character identifier of the first message description to be displayed or printed.

Element 2: Upper value

The second element of this parameter, called the ending message identifier, specifies the message identifier for the last message description to be printed. This value is ignored if OUTPUT(*) is specified.

*ONLY
Only the message identifier specified as a starting message identifier has its description printed.
*LAST
The last message in the file is the last message whose description is printed.
upper-value
Specify the 7-character identifier of the last message description to be printed.
Top

Message file (MSGF)

Specifies the message file from which the message descriptions are to be shown.

Qualifier 1: Message file

QCPFMSG
Message descriptions are shown from message file QCPFMSG.
name
Specify the name of the message file from which the message descriptions are shown.

Qualifier 2: Library

*LIBL
All libraries in the library list for the current thread are searched until the first match is found.
*CURLIB
The current library for the job is used to locate the message file. If no current library entry exists in the library list, QGPL is used.
*USRLIBL
Only the libraries in the user portion of the job's library list are searched.
name
Specify the library where the message file is located.
Top

Detail (DETAIL)

Specifies the amount of detail about the message that is displayed or printed.

*FULL
Detailed message descriptions are displayed or printed. If *PRINT is specified for the Output (OUTPUT) parameter, the detailed descriptions are printed. If an asterisk (*) is specified for the Output (OUTPUT) parameter, a menu is shown from which the user can select which details to view.
*BASIC
A list of the specified message identifiers, their severity, and messages are displayed or printed.
Top

Format message text (FMTTXT)

Specifies whether messages and help information are displayed or printed in a formatted style.

*YES
The messages and help information are displayed or printed in a formatted style.
*NO
The messages and help information are displayed or printed in an unformatted style.
Top

Output (OUTPUT)

Specifies whether the output from the command is displayed at the requesting work station or printed with the job's spooled output.

*
The output is displayed for interactive jobs or printed with the job's spooled output for non-interactive jobs.
*PRINT
The output is printed with the job's spooled output.
Top

Examples

Example 1: Displaying or Printing Descriptions

DSPMSGD   RANGE(CPF1100  CPF3600)  MSGF(QSYS/QCPFMSG)

If this command is entered from a display station, the descriptions of the specified messages are shown on the display. If this command is entered from a batch job, the descriptions of the messages are sent to the job's spooled output queue.

Example 2: Printing Message Descriptions

DSPMSGD   RANGE(*FIRST  IDU0571)  MSGF(QIDU/QIDUMSG)
          FMTTXT(*NO)  OUTPUT(*PRINT)

This command prints the message descriptions for message identifiers in the file that are in the following range: from the first message in the QIDUMSG message file through the message whose identifier is IDU0571. The message descriptions are not formatted.

Top

Error messages

*ESCAPE Messages

CPF2401
Not authorized to library &1.
CPF2407
Message file &1 in &2 not found.
CPF2411
Not authorized to message file &1 in &2.
CPF2483
Message file currently in use.
CPF2510
Message file &1 in &2 logically damaged.
CPF2515
Invalid message ID range.
CPF2516
Unable to open display or printer file &1 in &2.
CPF2519
Error occurred while processing message ID list.
CPF2537
Too many records written to file &2 in &3.
CPF9807
One or more libraries in library list deleted.
CPF9810
Library &1 not found.
CPF9830
Cannot assign library &1.
Top