Exception for read-only operations
There is an exception to the general rule about not switching between RLS and non-RLS within CICS®.
You can switch to non-RLS access on a data set that is normally opened in RLS mode provided access is restricted to read-only operations. You might want to do this, for example, to allow continued access for read-only transactions while the data set is being updated by a batch job. CICS and VSAM permit quiesced data sets to be opened in non-RLS mode, but you must ensure that CICS transactions do not update a data set that is being updated concurrently by a batch program.
- Resolve retained locks.
- Quiesce the data sets.
- Redefine the files as non-RLS and read-only mode in all relevant CICS regions. You
can do this using the CEMT, or EXEC CICS, SET FILE command.
Note: If your file definitions specify an LSR pool id that is built dynamically by CICS, consider using the RLSTOLSR system initialization parameter.
- Open the files non-RLS read-only mode in CICS.
- Concurrently, run batch non-RLS.
- When batch work is finished:
- Close the read-only non-RLS mode files in CICS.
- Re-define the files as RLS mode and with update operations. You can do this using the CEMT, or EXEC CICS, SET FILE command.
- Unquiesce the data sets.
- Open the files in CICS, if not using open on first reference.
- Resume normal running.
You should also take data set copies for recovery purposes before and after a batch run as you would normally, regardless of whether you are switching from RLS to non-RLS access mode.