I have a requirement where in I receive 6 files from upstream application into a GDG. I want to compare those all 6 version with one another to see any duplicates, i.e., it is a possibility that two or more files that came in may be duplicates (erroneously sent by upstream twice or multiple times). Could you please help on providing a solution using JCL or Cobol ?
how to compare multiple files using jcl
1.8k Views Asked by tanvi doiphode At
2
There are 2 best solutions below
0
Steve Ives
On
The best thing to do is to use the ISPF compare facility (ISPF 3.13 - SuperC or 3.13 - SuperCE) to compare the files but choose background execution rather than foreground. This will create a batch job which you can use as a template for steps to include in your job:
//SUPERC EXEC PGM=ISRSUPC,PARM=(DELTAL,LINECMP,' SEQ','')
//NEWDD DD DISP=SHR,DSN=new.dataset
//OLDDD DD DISP=SHR,DSN=old.dataset
//OUTDD DD SYSOUT=*
Bear in mind that ISPF compare only compares 2 files; to compare 6 you'll need 15 steps (I think).
If your site has PDSMAN, then you can use its PDSM37 module to generate a checksum for each datasets and a small REXX to easily compare the 6 checksums.
Related Questions in SORTING
- Sorting a List by its property renames all the objects in the List
- Does Sort() method in C# use recursion?
- ARM Assembly code is not executing in Vitis IDE
- Creating an efficent and time-saving algorithm to find difference between greater than and lesser than combination
- Heap sort with multithreading
- Laravel Livewire data table sorting livewire update payload
- basic MergeSort exercise
- How to import a range into a variant array in Excel VBA and sort using the sort method?
- Looker Studio | pivot chart - sorting by metric and last month
- how to create an array of multiples of 5 and display it in reverse
- matplotlib sort barh by values
- Custom Sorting Javascript with A-Z set
- Mainframe Programming Sorting, OUTFIL REMOVECC,NODETAIL
- Soft list based on another list
- SQL query : creating table with distinct values on selected columns
Related Questions in COBOL
- how to create an array of multiples of 5 and display it in reverse
- Z/OS Cobol 6.3 copy: how to include only a chunk?
- Trying to add gm and hm calculations to cobol program
- Cobol program wont read until end of file
- Cobol errors, cannot seem to figure it out
- Cobol file WRITE not allowed, file not open for output (status = 48) for file output-file
- Record grouping and aggregation
- open fetch and close cursor DB2
- How to create comments using only * in COBOL?
- DB2 contention issues
- Using the routine CSNBOWH on IBM I - MD5
- Addition of PIC 9 variable with space not causing ABEND S0C7
- FIlling a zone with S9(5)V9(8) COMP-3
- Microfocus COBOL - Remote debugging requires ALL programs to be compiled for debugging?
- VSCode snippet, how to force the starting column of a line?
Related Questions in MAINFRAME
- Where can I download ECI resource adapter (cicseci.rar). Unable to find out it in IBM portal
- Mainframe Programming Sorting, OUTFIL REMOVECC,NODETAIL
- Z/OS Cobol 6.3 copy: how to include only a chunk?
- SHA256 Checksum of a File transmitted from Mainframe to Azure
- open fetch and close cursor DB2
- How to "stack" an ISPF command?
- DB2 contention issues
- IBM z/OS TSO ISPF Editor Cancel command - how to add "Are You Sure?" query dialog
- FIlling a zone with S9(5)V9(8) COMP-3
- Mainframe monitoring using Zabbix
- How to programmatically overwrite DCI 2.0 policy via REXX or JCL?
- SEARCH ALL with a key PIC XX
- Why is this COBOL code failing to compile?
- Use MVS Dsname conventions. Mainframe name convention while downloading ftp using python
- COBOL issue (Compiling and executing)
Related Questions in JCL
- Mainframe Programming Sorting, OUTFIL REMOVECC,NODETAIL
- What are JCL Alternitives for Embeded Applications?
- Do I need delimiters on Dataset names for IDCAMS ALTER?
- How do i automate the JCL
- How to process non formatted numeric variable from SYSIN DD from JCL in COBOL
- How to programmatically overwrite DCI 2.0 policy via REXX or JCL?
- Sorting in JCL or COBOL
- How do I write current date and time to a sequential dataset using JCL?
- Replace using Sort in JCL
- I have a VB file of varying record length. I want to convert it in FB file
- Hi there, I am very new to mainframe and JCL, and I need some help understanding what this means/what I have to do
- Is a RECFM=VB dataset required to have a BDW?
- Update the trailer counts using JCL
- MVS ALLOCATE DDNAME to apply to multiple jobs
- Execute multiple JCL job with same name simultaneously
Related Questions in SYNCSORT
- A JCL or a SORTCARD that can split the input file into multiple output files based on size of the input file
- JCL SORT Decimal to Non decimal
- Syncsort produces a non-readable output for decimal(9,8) or smallint data type columns in Db2
- how to compare multiple files using jcl
- Using SORT in JCL, require only a maximum count after counting records group by
- Mainframe JCL to concat the 4 files in column wise, all the files having different number of rows,
- syncsort convert pd with precision to zdf
- Joining 2 datasets with SYNCSORT (JOINKEYS), is it possible to wildcard some of the values any way?
- Remove duplicates on specific record type using JCL sort
- Syncsort - Write UNPAIRED records to SORTOUT file, and PAIRED records to PAIRED file
- How can I solve "WER046A SORT CAPACITY EXCEEDED" in SYNCSORT JCL
- z/OS Syncsort: omit duplicates without sort
- How can we convert YYYYWWD format date into normal date format YYYY-MM-DD?
- How does DYNALLOC work when dealing with workfiles?
- Understand the following control cards
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
If they are properly strucured datasets (they are not files) then they should have header records. All you need do is compare the first record of each dataset. You could use your sort product or use ISRSUPC in batch.
JCL cannot do this as JCL only tells the operating system what programs and resources are needed to do the task. So even a COBOL solution would require JCL.
And, finally, I believe you are talking about generations no versions. Versions relate to the numbering after the GxxxxV.