CICS Tips.

A Mainframe-Tip a Day keeps the bugs away!
Forum rules
All of these Tips/Tuning-suggestions should be tested your own, at your shop, prior to use in Prod.
Post Reply
User avatar
Anuj Dhawan
Founder
Posts: 2799
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

CICS Tips.

Post by Anuj Dhawan »

1. When one needs to position the key to the last record in the VSAM data-set, while using a VSAM KSDS data-set in CICS - move HIGH-VALUES to the key field (RIDFLD) and then execute a STARTBTR. This will position the control on the last record of the data-set and a subsequent READNEXT or READPREV can be executed.
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
User avatar
Anuj Dhawan
Founder
Posts: 2799
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: CICS Tips.

Post by Anuj Dhawan »

2. You're using STARTBR and want to update a particular VSAM record? Following these steps will get you going:
  1. End the browse on the desired record by issuing a READ UPDATE.
  2. REWRITE after changing the the contents.
  3. Issue another STARTBR.
  4. Issue READNEXT twice*.
* - the first READNEXT will reread the same record

Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
User avatar
Anuj Dhawan
Founder
Posts: 2799
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: CICS Tips.

Post by Anuj Dhawan »

3. While testing, some time, while executing a CICS transaction, a transaction might hold the resources because it went in a loop. To terminate this event, use the following command:

Code: Select all

CEMT I TA(*)
With that, all the transactions, running, will get listed. Go to the transaction that is looping and issue FP command against it. This will forcefully purge the transaction and frees the buffer space.
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
User avatar
Anuj Dhawan
Founder
Posts: 2799
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: CICS Tips.

Post by Anuj Dhawan »

4. One can use the CETR transaction to to see if you have any unnecessary traces running. Once determined, remove any trace you don't need.

In application programming, it's advisable to use DFHRESP function to test the EIB return codes instead of using HANDLE conditions.
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
zprogrammer
Global Moderator
Global Moderator
Posts: 588
Joined: Wed Nov 20, 2013 11:53 am
Location: Mars

Re: CICS Tips.

Post by zprogrammer »

5.You can set the program enable or disable by providing

Code: Select all

CEMT SET PROG(name) ENA/DIS
The same can be done for Transaction as well
zprogrammer
zprogrammer
Global Moderator
Global Moderator
Posts: 588
Joined: Wed Nov 20, 2013 11:53 am
Location: Mars

Re: CICS Tips.

Post by zprogrammer »

6.You can call a CICS program from batch through. EXCI
zprogrammer
Quasar Chunawala
Registered Member
Posts: 34
Joined: Sun Aug 11, 2013 4:48 pm
Location: Pune

Re: CICS Tips - Online Job Submissions(OJS)

Post by Quasar Chunawala »

7. Online Job Submissions
Sometimes an online application may need to trigger and run a batch job for processing a large workload, asynchronously. EXEC CICS SPOOLOPEN and EXEC CICS SPOOLWRITE allow you to write information to a SYSOUT dataset. If you write JCL statements to a SYSOUT dataset using SPOOLWRITE and as input to INTRDR, it would submit the JCL.
Quasar Chunawala
Registered Member
Posts: 34
Joined: Sun Aug 11, 2013 4:48 pm
Location: Pune

Re: CICS Tips.

Post by Quasar Chunawala »

8. CICS Dump Analysis -
If you don't have a dump analysis tool like Dump Master at your shop and you like to find out the instruction where the program failed, here's a CICS transaction dump cookbook, which lays down steps on how to find the COBOL statement, WS- or LS-Variable state from the dump.

ftp://ftp.software.ibm.com/software/my/ ... -Dumps.pdf
Interesting - I learnt that in core memory, addressing each 4K block needs a Base Locator. So, you'd have a BLW0, BLW1, BLW2 for each 4k chunk. The BLLs/BLWs addresses can be found in the TGT memory map at the end of the compile listing. And the TGT's address can be found in GPR09(Registers at the time of Interrupt.
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “Tip Of the Day.”