Hi,
I am trying to define multiple keys for the same physical file and the scenario is as explained below:
I have two files: File1 and File2. I am supposed to define a composite key (Field-1+Field2) for both the files. But either of these two fields defined as a key could change (but not both at the same time) as File1 is from yesterday's batch run and File2 is from today's run (some update activity processed in today's run could've changed the value of Field-1 or Field-2 in File2). This change does not happen for all the records, meaning I have to use the originally defined composite key (Field-1+Field-2) for finding the matching records. For the records in File2 with change in the value of Field-1, Field-2 must be used as key and Field-1 for those records with change in the value of Field-2. I have an indicator to identify which record has changes in Field-1 and which has changes in Field-2.
Please help me on how to code multiple keys for the same physical file. I can use different DD name for the same physical file but is it possible to switch to a second key for the record which can not be processed using the first key?
I will be grateful if you could throw some light on handling this scenario in Easytrieve.
Many thanks,
Sivaguru
Doubt in using multiple keys for same physical file in EZT
Moderators: DikDude, Moderator Group
Doubt in using multiple keys for same physical file in EZT
Thanks,
Sivaguru
Sivaguru
FREE TUTORIALS
Tutorials
Free tutorials from mainframegurukul
- JCL Tutorial
Covers all important JCL concepts. - Cobol Tutorial
This tutorials covers all Cobol Topics from STRING to COMP-3. - DB2 Tutorial
DB2 Tutorial focuses on DB2 COBOL Programming. - SORT Tutorial
This Tutorial covers all important aspects of DFSORT with examples - CICS Tutorial
This CICS tutorial covers CICS concepts and CICS Basics, CICS COBOL Programming.
Interview
Mainframe Interview questions
- Cobol Interview Questions
50+ Interview Questions - JCL Interview Questions
50+ Interview Questions - DB2 Interview Questions
100+ Interview Questions - CICS Interview Questions
70+ Interview Questions - VSAM Interview Questions
27 Interview Questions
Other References
Mainframe Tools and others
- XPEDITER Reference
Explains how we can debug a program - FILEAID Reference
Explains how to browse , edit and delete datasets - Change Man Reference
Quick Start tutorial on Changeman - Abend Reference
Important Abend codes explained - FaceBook Page
MainframeGurukul FaceBook Page - LinkedIn Page
MainframeGurkul Linkedin Page