IBM Support

Creating Reply List Entries

Troubleshooting


Problem

The Reply List Entry feature for the operating system provides a useful and convenient method for automatically answering messages.

Resolving The Problem

The Reply List Entry feature for the operating system provides a useful and convenient method for automatically answering messages. It allows an operator to specify the messages to which a reply is automatically given, the reply to be given, and also allows different replies to the same message based on information within the message. For example, a verify alignment on printer message for PRT01 could be answered with I, while the same message for PRT02 could be answered with G.
        • To add a Reply List Entry, use the Work Reply List Entry (WRKRPYLE) command. You are shown the following:
           
                               Work with System Reply List Entries
                                                                 
          Type options, press Enter.                              
           2=Change   4=Delete                                  


                 Sequence  Message                                                                    Compare
          Opt   Number           ID     Reply       Compare Value    Start
          __        1         CPA3709    G             *NONE                                
          __       10         CPA0700    D             *NONE                                
          __       30         CBE0000    D             *NONE                                
          __       40         PLI0000    D             *NONE

Suppose we wish to add an automatic reply for message, CPA4002, Verify alignment on printer &3. (I G N R E C).

Use F6 to add a new entry. You are shown the following:
 
Type choices, press Enter.                                            
                                                                     
Sequence number  . . . . . . . .                   1-9999                
Message identifier . . . . . . .                     *ANY        Character value, *ANY
Compare data:                                                          
    Comparison data  . . . . . . .                 *NONE                              
    Message data start position  .                 *NONE        1-999,  *NONE          
Message reply  . . . . . . . . .                     *DFT

You must choose a unique sequence number that is not already in use. In the example, we used 50 because it is unused. The message ID is CPA4002. In our first example, assume that we want CPA4002 answered with I every time it is sent. Therefore, do not type anything in the Compare data field. For Message reply, type I:
 
Type choices, press Enter.                                            
                                                                     
Sequence number  . . . . . . . .                   50                           1-9999                
Message identifier . . . . . . .              CPA4002            Character value, *ANY      
Compare data:                                                          
    Comparison data  . . . . . . .             *NONE                              
    Message data start position  .             *NONE            1-999,  *NONE          
Message reply  . . . . . . . . .                  'I'

Suppose, however, you want to answer with I for PRT01, and G for PRT02. To do that, you must know where in the message the printer is specified. The system is testing an unformatted character string, and you must know where in that character string the printer ID begins.

To find that, on the OS/400 command line type the following:

DSPMSGD CPA4002

Press the Enter key. You are shown a menu with a series of options. Before selecting any option, note in the message text which field contains the printer name. In the case of CPA4002, you see:

Verify alignment on printer &3. (I G N R E C)

The name of the printer is in parameter &3.

On the menu, select Option 2, "Display field data." You are shown the following:
 
                                    Decimal       Vary          
Field     Data Type     Length     Positions     Length     Dump
&1       *CHAR            10                               *NO
&2       *CHAR            10                               *NO
&3       *CHAR            10                               *NO
&4       *BIN              2                               *NO
&5       *CHAR            10                               *NO

Note: The offsets within the message may vary by release. It is possible that you may see something different from this example for message CPA4002. You also may find that, after an upgrade, a Reply List Entry no longer works properly. If so, check the message description to see if the offset for the parameter used in the Reply List Entry changed.

From the display of the field positions, we know that the first parameter, &1, has a length of 10. Therefore, it will occupy positions 1 through 10. The second parameter, &2, also has a length of ten. Therefore, it occupies positions 11 through 20. The third parameter, &3, contains the printer name, is 10 characters beginning in position 21. To add a Reply List Entry for PRT01 with an automatic reply of I, type the following:
 
Type choices, press Enter.                                            
                                                                     
Sequence number  . . . . . . . .                50                       1-9999
Message identifier . . . . . . .           CPA4002        Character value, *ANY              
Compare data:                                                          
    Comparison data  . . . . . . .        'PRT01'                              
    Message data start position  .             21                1-999,  *NONE          
Message reply  . . . . . . . . .               'I'

Note: Entries for Comparison data and Message reply are enclosed in apostrophes. This is required.

A similar entry for PRT02 might look like this:
 
Type choices, press Enter.                                            
                                                                     
Sequence number  . . . . . . . .                   60                           1-9999                
Message identifier . . . . . . .              CPA4002               Character value, *ANY    
Compare data:                                                          
    Comparison data  . . . . . . .           'PRT02'                              
    Message data start position  .                21                           1-999,  *NONE          
Message reply  . . . . . . . . .                  'I'

After creating the reply list entry (or entries), you must tell the jobs to use them. A job does not automatically look to the System Reply List to see if a message should be answered automatically. You must specify what you want the job to do so.

That can be done in the following ways. The easiest and most common is to specify in the Job Description for the job that we want the job to determine the System Reply List. In the example, you use the Job Description, QDFTJOBD.
1. On the operating system command line, type the following:

WRKJOBD QDFTJOBD

Press the Enter key. Select Option 2, Change.
2. Press F10, Additional parameters.
3. Page down two times.
4. Look at the field, Inquiry message reply . . . . . *RQD.

*RQD,
means, Required. The Operator is required to enter a reply. If *SYSRPYL (System Reply List) is substituted, any program using QDFTJOBD looks to the System Reply List to determine if the message matches any entry in the list. If it does, it uses the reply specified in that entry.
Note: Any job already running when you change the Job Description does not use the change made until the next time that job runs. If a job is already running, and the Job Description had Inquiry message reply . . . . . *RQD specified when the job started, it continues to run with a value of *RQD for Inquiry message reply and does not look to the System Reply List for message replies.

[{"Type":"MASTER","Line of Business":{"code":"LOB57","label":"Power"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SWG60","label":"IBM i"},"Platform":[{"code":"PF012","label":"IBM i"}],"Version":"7.1.0"}]

Historical Number

476923857

Document Information

Modified date:
13 November 2020

UID

nas8N1013899