Module 12: CICS Resource Definitions and Administration
File Definitions
A FILE definition connects the 8-character file name your program uses in EXEC CICS READ/WRITE/REWRITE/DELETE to a real VSAM or BDAM data set on disk.
What a file definition contains
- FILE - the 1 to 8 character name used in EXEC CICS file commands, for example ORDFIL.
- DSNAME - the data set name on disk, for example SHOP.ORDER.KSDS.
- OPENSTATUS - OPEN opens the file at install; CLOSED leaves it closed until you open it with CEMT.
- ADD, BROWSE, DELETE, READ, UPDATE - YES/NO switches controlling which operations are allowed.
- DISPOSITION - SHR shares the data set with other regions; OLD gives this region exclusive use.
- STRINGS - number of concurrent requests the file can handle; too few causes waits.
- LSRPOOLID - which local shared resources pool buffers the file, for performance tuning.
- RECORDSIZE and KEYLENGTH describe the VSAM record layout CICS should expect.
Opening, closing and sharing files
- A file defined OPENSTATUS(OPEN) is ready the moment its group is installed.
- Open or close a file any time with CEMT SET FILE(filename) OPEN or CLOSED - no reinstall needed.
- DISPOSITION(SHR) is normal for files shared between regions; the data set must really be shareable (VSAM SHAREOPTIONS).
- For sysplex-wide record-level sharing, use RLSACCESS(YES) so VSAM RLS handles integrity instead of CICS.
- Closing a file with CEMT while tasks use it waits or fails - quiesce the application first.
Example - define a KSDS and open it:
CEDA DEFINE FILE(ORDFIL) GROUP(ORDGRP)
DSNAME(SHOP.ORDER.KSDS)
OPENSTATUS(OPEN)
ADD(YES) BROWSE(YES) DELETE(YES) READ(YES) UPDATE(YES)
DISPOSITION(SHR)
STRINGS(10)
LSRPOOLID(1)
CEDA INSTALL GROUP(ORDGRP)
CEMT SET FILE(ORDFIL) OPEN
