CICS in a nutshell

Swathi Javvaji
5 min readMar 1, 2022

When a Modern Mainframe DevOps Engineer works on legacy products it is adequate to know the basics in order to support or maintain them. However, when the developer has to come out of the comfort zone to enhance the product with the core mainframe technology, it is nerve-wracking without proper guidance or exposure.

I was in a similar situation and had to do a lot of research to find out “what to learn and what was important” in CICS. I would like to share my journey of learning CICS in brief.

I started off by researching on the internet, reading redbooks, watching YouTube channels, and asking around for help. It was time taking and I felt lost. I even signed up for interskill, udemy courses for learning.

After gaining a basic understanding of CICS, I felt one has to learn the below topics to understand CICS.

What is CICS?

CICS (Customer Information Control System) is a system, which allows users to develop and execute online applications in an MVS environment. It is a command-level language that consists of a set of commands, coded in the Procedure Division.

Sample code from a COBOL program

Why CICS?

Using CICS, users can share their applications, program, and data files. The system is simple, robust, and compatible. CICS is used by the online banking system, insurance companies, and airline reservation systems. CICS programs can be written in COBOL, Assembler, PL/I, C, C++, Java…

Features of CICS

CICS is OLTP (Online Transaction Processing system) which means it is an online system consisting of transactions.

A transaction is a logical unit of work, which is initiated by a single request that may affect one or more objects.

It is an Operating System in itself with its own processors, file management systems, test manager and provides DB/DC facilities.

What are the major components in CICS?

Data Communication Functions: It is the interface between CICS and terminals.

Data Handling Functions: Interface with Data Access Methods such as VSAM and Database Access Methods such as DB2, IMS/DB, IDMS.

Application Program Services: Interface with COBOL, PL/I, Assembler programs.

System Services: Interface between CICS and operating system. Also storage control such as acquiring and freeing resources.

Monitoring Functions: Monitors various events within CICS and provides statistics.

Structure of the components
Structure of different components

Since we understand by now that CICS is mainly comprised of transactions, what exactly is a transaction, and what are the default system-defined transactions.

A transaction is a unit of work that is done as an atomic operation and is identified by a four-character ID like T4Z0, T4Z1, T4Z2 that are user-defined. Some of the system-defined transactions are CEMT, CEDA, CEDF, CECI, CEBR, CESF, and CESN. (Usually starting with letter “C”)

CEMT — CICS Execute Master Terminal

CEDA — CICS Execute Definition and Administration

CEDF — CICS Execute Debug Facility

CEBR — CICS Execute Browse

CESN — CICS Execute Sign-On

CECI — CICS Execute Command Interpreter

CMAC — CICS Messages for ABEND Codes

CESF — CICS Execute Sign Off

A transaction is initiated by using the TRANSID. Once a transaction is initiated, a lot of programs are invoked internally for the transaction to work.

CICS Nucleus

TCP, KCP, PCP, FCP are all CICS control programs.

Control Programs in CICS

Program Control Program (PCP): It governs the flow between CICS and CICS application programs.

File Control Program (FCP): It provides manipulation services to the application programs.

Terminal Control Program (TCP): It provides communication services between application programs and terminals.

Task Control Program (KCP): It is used to control the execution of tasks simultaneously and their related properties.

System Initialization Program (SIP): It is used to initialize the program in the communication area.

Transient Data Control Program (TDP): It allows application programs with the ability to store and retrieve data from Transient Data Queues.

Storage Control Program (SCP): It is used to control the allocation and deallocation of storage within the CICS region.

Apart from these control programs in CICS, there are some other programs that CICS uses.

Data Entry Programs (These programs accept input data from user and use it to update the files after validating the data entered)

Inquiry Programs (These programs can provide response to a user’s inquiry)

File Maintenance Programs (These programs can update a file by adding, changing or deleting records)

Menu Programs (These programs allows the user to select a particular function)

One more important topic in CICS is multi-tasking.

What is multi-tasking?

The answer is pretty straightforward. Handling multiple tasks at a time. Wow ! Easy! But what is a task in CICS?

A task is nothing but an instance of the execution of a particular transaction type.

For e.g., Let us say 100 users execute a transaction, and then 100 tasks are created. It means the OS allows more than one task to be executed concurrently, regardless of whether the task uses the same program or different programs.

Multi-Threading means multiple users execute a single program concurrently.

Next we have to know how does communication happens in CICS. There are two modes.

Conversation Mode- It means sending a message to the terminal and wait for the user to respond. Since there is waiting time, the computer resources are wasted.

Pseudo Conversation Mode- It means sending a message to the terminal and the control does not wait for the user to respond, instead it is sent to some other task. Since there is no waiting time, the resources are used optimally.

BMS role in CICS

BMS(Basic Mapping Support) is provided by CICS to help you define and format screens. The screen is developed with a MAPSET.

Mapset: Collection of maps link-edited together to create a load module. DFHMSD is the macro which defines a map set.

Map: It is a single screen format. DFHMDI is a macro that defines a map. A map is a collection of Fields and the macro to define fields is DFHMDF.

BMS acts as an interface between the CICS program and the Terminal Device.

Map Definition in MAPLIB

Now that you know the basics, I will try to explain small programs and navigation in CICS screens in future.

Please stay tuned to know more interesting topics in the next blog.

--

--