Skip to content

MDADDSRQ - Generate Object Request Records for Send RFP command

MDCMS is delivered with a command-based API that allows external tools or applications to create Object Requests within an RFP in the send list in MDCMS.

The MDCMS command is named MDADDSRQ and is located in library MDCMS. It is not necessary to have the MD libraries in the library list prior to using this command. If you are unable to invoke a command from your tool, you can also directly call program MDADDSRQ in library MDCMS. In this case, be certain that the parameter order and formats sent to the program exactly match the parameters in command MDADDSRQ.

All MDADDSRQ API transactions are logged to file MDCMS/MDDASRQ.

MDADDREQ Parameter Table

Name Type Length Description
KEYWORD Description Type Length
APPL Application CHAR 6
LVL Level INTEGER 3
OBJT Object Type CHAR 7
ATTR MDCMS Attribute CHAR 10
OBJN Object Name CHAR 128
RPTH Object Relative Path CHAR 240
SRCN Source Name CHAR 128
RSN Request Reason CHAR 10
USER Programmer CHAR 10
PROJ Project CHAR 12
TASK Task INTEGER 7
STSK Subtask INTEGER 7
ARFP Assign RFP CHAR 4
RFP RFP Number INTEGER 7
RFPD RFP Description CHAR 160
CREQ Create Requests for Next Level CHAR 4
AREQ Assign RFP to Next Level Reqs CHAR 7
SREQ Place RFP in Send List CHAR 7
CSQO Compile Subsequence INTEGER 5
DATA Data Origin CHAR 60
DMBR Data Member to Copy CHAR 10
RPGM Use MDRapid CHAR 10
RJRN Reapply Journals CHAR 4
RCST Reapply Constraints CHAR 4
RTRG Reapply Triggers CHAR 4
RLFM Reapply LF Members CHAR 4
DIR Is IFS Directory CHAR 4
ENV MDCMS Environment ID CHAR 4
VREF Vendor Reference ID CHAR 20
EMSG Exception Message CHAR 7

Detailed Description of MDADDREQ Parameters

Application (APPL)

The target MDCMS Application code for the request

This is a required parameter.

Level (LVL)

The local MDCMS Promotion Level for the request to be sent from.

This is a required parameter.

Object Type (OBJT)

The System or MDCMS Object Type code for the Object. For example: *PGM for a program or *IFS for an IFS file.

This is a required parameter.

MDCMS Attribute (ATTR)

The MDCMS Attribute code that identifies the behaviour and target locations for the requested object.

This is a required parameter.

Object Name (OBJN)

The name of the Object to be requested.

For *SOURCE, this would be the name of the member

For *MSGD, this would be the name of the Message ID

For *DTAGRP, this would be the value of the record key(s)

This is a required parameter.

Relative Path (RPTH)

Specifies the relative portion of an IFS path, starting with /, that will be deployed with the object.

For example, if the *IFS attribute has a target fixed directory defined as /srv/dev and this object should be deployed to /srv/dev/app1/dist, then the value of RPTH should be /app1/dist.

Member/IFS File Name (SRCN)

Specifies the name of the Source Member or IFS Source File to be requested. This parameter is ignored if attribute defined as having no source.

*OBJ - The name of the source is the same as the name of the object

Request Reason (RSN)

The reason for the object request

*MIGRATE - a source and/or object will be migrated into the selected application level

*DELETE - an existing object will be deleted

*RECOMPILE - an object will be recompiled based on the currently active source for that environment without the source being modified

*UPDATE - this is intended for ILE programs to bind the current modules and service programs to the program. A U command (such as CHGPGM) must be defined for the attribute.

Programmer (USER)

Specifies the user profile to be indicated as the programmer for the request. If this command generates an RFP, the owner of the RFP will also be this user

*USER - the current user profile of the job invoking this command is the user

Project (PROJ)

Specifies the Project to assign to the Request. The project, if entered, must already exist and be in an open status. If the project is not yet authorized, then the user must have MDSEC authority to authorize the Project and then MDCMS will do so automatically.

Task (TASK)

Specifies the Project Task to attribute to the Request. The task, if entered, must already exist and be in an open status.

Subtask (STSK)

Specifies the Subtask to attribute to the Request. The Subtask, if entered, must already exist and be in an open status.

Assign Request to RFP (ARFP)

Specifies if the request should be immediately assigned to an RFP and the method of determining the RFP.

*AUTO - MDCMS searches for an open RFP matching the Application, Level, User and Description values entered for this command. If an RFP is found the Request will be assigned to that RFP. If an RFP is not found, a new RFP will be created.

*YES - The request will be assigned to the RFP number based on parameter RFP

*NEW - A new RFP will be created for the Application, Level, User and Description values entered for this command.

Existing RFP Number (RFP)

Specifies the RFP to assign to the Request. Will only be used if parameter ARFP is set to *YES.

RFP Description (RFPD)

The description to be used for a new RFP or to search for an existing RFP. Will only be used if parameter ARFP is *AUTO or *NEW.

Compile Subsequence (CSQO)

Specifies the sequence for compiling (lowest first) for objects in same RFP that have the same primary sort sequence in order to handle potential dependency issues. This parameter is not relevant for *IFS Objects.

Data Origin for Physical Files or SQL Tables (DATA)

Specifies the origin of the data that should be copied into a new or modified physical file/SQL Table

*SAME - The data is mapped from the old format of the modified file to the new format of the file of the same name/target library.

*MIGRATE - The data is migrated with the file from the check-out location to the target library.

*NONE - The data is not migrated. The new file format will be empty. *NONE is required for a logical file if it is replacing a physical file.

character-value - Specify the name of the file from which to migrate the data. The data origin file must exist in the same library as the target file at the time of installation.

Data Member to Copy (DMBR)

Specifies the member(s) to copy to the new version of a physical file/SQL Table or to migrate from the prior environment.

*ALL - All existing members are included for the copy. If the target is an SQL Table, only the first member will be copied.

*FIRST - The first member in the originating file is copied. Any other members are omitted.

character-value - The name of the specific member to be copied from the originating file. Any other members are omitted.

Use MDRapid (RPGM)

Specifies if MDRapid should be used to map the data from the old version of a file to the new version.

*DFT - MDRapid will be used if the number of records in the file is at least the number in the MDRapid template for the attribute. Otherwise not.

*YES - MDRapid will be used for the file, even if it wouldn't qualify for MDRapid processing.

*NO - MDRapid will not be used for the file, even if it would qualify for MDRapid processing.

Automatically Reapply Journaling (RJRN)

Specifies if the new version of a table or access path should have the journaling attributes applied to it that belonged to the file that it replaced.

*DFT - The default defined for the Application is used

*YES - If journaling was used on the prior version of the file, it will be applied to the new version.

*NO - Journaling will not be automatically reapplied. Commands run during the installation, or external processes, will determine the definition.

Automatically Reapply Constraints (RCST)

Specifies if the new version of a table should have the constraints applied to it that belonged to the table that it replaced.

*DFT - The default defined for the Application is used

*YES - If constraints were used for the prior version of the table, they will be applied to the new version.

*NO - Constraints will not be automatically reapplied. Commands run during the installation, or external processes, will determine the definition.

Automatically Reapply Triggers (RTRG)

Specifies if the new version of a table should have the system (non-SQL) triggers applied to it that belonged to the table that it replaced.

*DFT - The default defined for the Application is used

*YES - If SQL triggers were used for the prior version of the table, they will be applied to the new version. Any SQL triggers that should be re-applied should be requested for recompile and placed on same RFP as the file.

*NO - Triggers will not be automatically reapplied. Commands run during the installation, or external processes, will determine the definition.

Automatically Reapply Logical File Members (RLFM)

Specifies if the new version of a logical file should have the members added to it that belonged to the logical file that it replaced.

*DFT - The default defined for the Application is used

*YES - Any members that existed for the prior version of the logical file will be added to the new version.

*NO - Members will not be automatically reapplied. Commands run during the installation, or external processes, will determine the definition.

IFS Object is a Directory (DIR)

Specifies whether or not the Request of an object of type *IFS is a directory.

*NO - The Requested Object is not an IFS Directory

*YES - The Requested Object is an IFS Directory

Environment ID (ENV)

Specifies the MDCMS environment that should be used to place the Request. The ID correlates to the suffix of the MDCMS library name. For example, TEST correlates to library MDCMSTEST.

*DFT - The default environment will be used. This correlates to library MDCMS.

Vendor Reference ID (VREF)

Specifies the Vendor Generated Identifier in order for an external process to easily identify the transaction record in the MDDAREQ table. Any value up to 20 characters in length can be used.

Exception Message Returned (EMSG)

Specifies if and to what extent an exception message should be returned to the calling program. An exception message occurs when an input parameter value is invalid, causing the addition of the request to fail.

*DIAG - A diagnostic message will be placed in the calling program's message queue in the following format:

MDADDREQ Exception. Object=, Vendor Reference=, Reason=

If the Vendor Reference isn't passed to MDADDREQ, it won't be included in the diagnostic message.

*ESCAPE - The full diagnostic message as described above will be placed in the calling program's message queue and then followed by escape message CPF0001 for which the calling program can monitor.

*NONE - An exception message will not be returned to the calling program's message queue.