With DADS Plus CICS can you switch to the alternate and the primary file at the class level for all files in the class?

Document ID : KB000105709
Last Modified Date : 06/07/2018
Show Technical Document Details
Question:
The client uses the alternate files feature when using CA DADS. When switching to alternate files with CA DADS do you have to have individual CA DADS entries for each file? Or can you switch to the alternate file at the CLASS level for all files in the class?
Environment:
Z/OS 
CICS
Answer:
You can switch to alternate and primary files using classes using the .A or the .P after the class name as shown below.
The example below is using Batch jobs. You can also switch at the CLASS level using the CA DADS online menus-transaction DADA..
 
//SYSIN DD *
FUNCTION=DADS,APPLID=(A11IC4S6,QUEUE)
REQUEST=(A,C,CLASSALT.P)
 
For the primary
Or
 
//SYSIN DD *
FUNCTION=DADS,APPLID=(A11IC4S6,QUEUE)
REQUEST=(A,C,CLASSALT.A)
 
For the alternate
 

I did the following test using a CA DADS batch job. I have two files FILE001 and FILE002 in class CLASSALT. Both files have an alternate file define in the  CA DADS entry.
 
When I start my CICS region the files are allocated to the primary cluster name.
 
F:FILE001 SUPPORT.FILE001 ALA OPE ENA
F:FILE002 SUPPORT.FILE002 ALA OPE ENA
 
I then run a batch job. Step 1 to deallocate the class and step 2 to allocate the alternate dataset.
 
FUNCTION=DADS,APPLID=(A11IC4S6,QUEUE)
REQUEST=(A,C,CLASSALT.A)
 
 
The batch output shows
 
FUNCTION=DADS,APPLID=(A11IC4S6,QUEUE)
REQUEST=(A,C,CLASSALT.A)
CONDITION CODE=000 DADSA460 REQUEST COMPLETED SUCCESSFULLY.
 
 
Online in DADS the DADI transaction shows the two alternate files allocated.
 
F:FILE001 SUPPORT.FILE001.ALT ALA OPE ENA
F:FILE002 SUPPORT.FILE002.ALT ALA OPE ENA