TSO-ISPF JCL COBOL VSAM DB2 CICS IMS-DB IMS-DC Tools Articles Forum Quiz Interview Q&A

Defining MFS Messages

The MFS facility of IMS controls formatting of IMS online messages. When a message is sent to a display device such as a 3278 or 3178 terminal, certain keys perform special functions and need not be defined within the MFS format. These keys are as follows:

  • PA1 - Used for logical paging (described later in this section).

  • PA2 - Used to retrieve the next message waiting for the device.

  • ENTER - Sends the message to the IMS Control Region to be processed.

MFS was designed so that an application program could send messages to devices and be device-independent. This independence allows messages to be sent to different devices without changing the application program code. Only the message format need be regenerated for the new device.

MFS works with a set of control blocks that define how the message will be formatted to the client and the application program. The blocks also define how sending and receiving devices will format the message. Four control blocks are involved in creating a message with MFS:

  • Device Input Format (DIF)

  • Message Input Descriptor (MID)

  • Message Output Descriptor (MOD)

  • Device Output Format (DOF)

The flow of an MFS message between a client and an online program is shown in Figure below.


The processing of a message starts with a client entering data on an MFS- supported device. When the ENTER key or a PF key, is pressed, a message is transmitted to IMS. IMS analyzes the message to see if the following applies:

  • It is an IMS operator command that it has to respond to.

  • It is message to be sent to another device.

  • An application program needs to be scheduled.

The message needs to be passed to MFS for further formatting.

If the message is to be passed to MFS, it is formatted based on the associated DIF. MFS reformats the message, removing all device-dependent data, according to the MID definition. The message is sent to the application program for processing. Once the message is processed, the program edits and sends a response back to the originating client.

Again, IMS edits the message, and passes it back to MFS if MFS is required. MFS interprets the data sent from the application program using the MOD control block. It then creates the screen to be sent to the client by combining the interpreted data with the DOF control block.

If you have any doubts or queries related to this chapter, get them clarified from our Mainframe experts on IBMMainframer Community!

Are you looking for Job Change? Job Portal