Merge Message Catalog (MRGMSGCLG)

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

The Merge Message Catalog (MRGMSGCLG) command merges message text from one or more source files (SRCFILE parameter) with message text in the specified message catalog (CLGFILE parameter). If the catalog specified does not already exist, it will be created using values specified for the CLGCCSID, DTAAUT, and OBJAUT parameters. If the catalog already exists, the CCSID, DTAAUT, and OBJAUT attributes of the existing message catalog will be used.

You can specify up to 300 message text source files. Message text source files are processed in the sequence specified. Each successive source file modifies the catalog. If a message number in the source file already exists in the message catalog, the new message text defined in the source file replaces the old message text in the message catalog file. If a message number in the source file does not already exist in the message catalog, the message information is added to the message catalog.

This command can also be issued using the following alternative command name:

Top

Parameters

Keyword Description Choices Notes
CLGFILE Message catalog name Path name Required, Positional 1
SRCFILE Source file path name Values (up to 300 repetitions): Path name Required, Positional 2
CLGCCSID Message catalog CCSID 1-65533, *SRCCCSID, *JOB Optional
TEXT Text 'description' Character value, *BLANK Optional
SRCCCSID Source file CCSID 1-65533, *SRCFILE, *JOB Optional
DTAAUT Public authority for data Name, *INDIR, *NONE, *RWX, *RX, *RW, *WX, *R, *W, *X, *EXCLUDE Optional
OBJAUT Public authority for object Single values: *INDIR, *NONE, *ALL
Other values (up to 4 repetitions): *OBJEXIST, *OBJMGT, *OBJALTER, *OBJREF
Optional
Top

Message catalog name (CLGFILE)

Specifies the path name of the message catalog to be changed or created. All directories in a stream file path name must exist. If no stream file exists with the specified path name, a message catalog with the specified file name is created. If the path name is in the QSYS file system, the file must exist. If a file member in the QSYS file system does not exist, it is created. Source physical files with multiple data fields are not supported.

Top

Source file path name (SRCFILE)

Specifies the path name of the source file that contains the message text to be merged into the message catalog. If the file is from the QSYS file system, then it must be a database source physical file.

Note: If the source file is not a record file, then each line in the source file must have been terminated with a newline or linefeed character when the source file was created.

Top

Message catalog CCSID (CLGCCSID)

Specifies the coded character set ID (CCSID) in which to store the message text in the message catalog. If the message catalog is a stream file, the CCSID value entered is used to set the stream file's attributes. Use the Work with Object Links (WRKLNK) command to display the CCSID of a message catalog. Use the Display File Description (DSPFD) command to determine the CCSID of a message catalog in the QSYS file system.

The possible values are:

*SRCCCSID
Special value indicating that the CCSID will be determined from the value specified for the source file CCSID (SRCCSID parameter).
*JOB
Special value indicating the job CCSID is used for the catalog information. If the job CCSID is 65535, the job default CCSID is used.
coded-character-set-ID
Specify the CCSID used for the catalog information. The values 0, 65534, and 65535 are not valid.
Top

Text 'description' (TEXT)

Specifies the text that briefly describes the message catalog.

Note: Assigning text to objects is dependent on the support provided by the file system or object type used for the message catalog.

The possible values are:

*BLANK
The mode name consisting of 8 blank characters is used.
'description'
Specify no more than 50 characters of text, enclosed in apostrophes.
Top

Source file CCSID (SRCCCSID)

Specifies the coded character set ID (CCSID) of the source file.

The possible values are:

*SRCFILE
Special value indicating that the CCSID will be determined from the CCSID of the first source file (SRCFILE parameter).
*JOB
Special value indicating the job CCSID is used for the CCSID of the source file. If the job CCSID is 65535, the job default CCSID is used.
coded-character-set-ID
Specify the CCSID of the source file. The values 0, 65534, and 65535 are not valid.
Top

Public authority for data (DTAAUT)

Specifies the public authority given users for the data in the object created.

The possible values are:

*INDIR
The authority for the object being created is determined by the directory it is being created in. If *INDIR is used for DTAAUT, it is also required for OBJAUT.
*RWX
The users are given *RWX authority to the objects. *RWX authority allows the user to perform all operations on the object except those limited to the owner or controlled by object existence, object management, object alter, and object reference authority. The user can change the object and perform basic functions on the object. *RWX authority provides object operational authority and all the data authorities.
*RX
*RX authority allows the user to perform basic operations on the object, such as run a program or display the contents of a file. The user is prevented from changing the object. *RX authority provides object operational authority and read and execute authorities.
*RW
*RW authority allows the user to view the contents of an object and modify the contents of an object. *RW authority provides object operational authority and data read, add, update, and delete authorities.
*WX
*WX authority allows the user to modify the contents of an object and run a program or search a library or directory. *WX authority provides object operational authority and data add, update, delete, and execute authorities.
*R
*R authority allows the user to view the contents of an object. *R authority provides object operational authority and data read authority.
*W
*W authority allows the user to modify the contents of an object. *W authority provides object operational authority and data add, update, and delete authorities.
*X
*X authority allows the user to run a program or search a library or directory. *X authority provides object operational authority and data execute authority.
*EXCLUDE
Exclude authority prevents the user from accessing the object. The OBJAUT value must be *NONE if this special value is used.
*NONE
The users will not be given any of the data authorities to the objects. This value cannot be used with OBJAUT value of *NONE.
authorization-list-name
Specify the name of the authorization list used.
Top

Public authority for object (OBJAUT)

Specifies the authorities given users to the object.

The possible values are:

*INDIR
The object authority is based on the authority for the directory where this object is being created. If *INDIR is used for DTAAUT, it is also required for OBJAUT.
*NONE
None of the other object authorities (existence, management, alter, or reference) will be given to the users. If *EXCLUDE or an authorization list name is specified for the DTAAUT parameter, this value must be specified.
*ALL
All of the other object authorities (existence, management, alter, and reference) will be given to the users.

Or specify up to four (4) of the following values:

*OBJEXIST
The users will be given object existence authority to the object.
*OBJMGT
The users will be given object management authority to the object.
*OBJALTER
The users will be given object alter authority to the object.
*OBJREF
The users will be given object reference authority to the object.
Top

Examples

MRGMSGCLG   CLGFILE('/USDIR/USMSG.CAT')  CLGCCSID(*SRCCSID)
            SRCFILE('/QSYS.LIB/MYLIB.LIB/MSGSRC.FILE/USMSG.MBR')
            DTAAUT(*R)  TEXT('Message catalog for USA')

This command merges the message text from member USMSG of source physical file MSGSRC in library MYLIB in the QSYS file system with message catalog USMSG.CAT in directory USDIR. If the message catalog does not already exist, it will be created with the CCSID of the source file and data authority of *R. The text parameter describes this as a message catalog for the USA.

Top

Error messages

*ESCAPE Messages

CPF3BE3
Message catalog &1 not created or updated.
Top