Join matching keys for more than two files
Posted: Mon Aug 03, 2015 4:39 pm
Hi All,
I have got in a new requirement, where in multiple files need to be scanned for a common key across them and if found, then we need to reformat the matched key records from multiple files.
INPUT:
FILE1: 123ABCDEFGH
FILE2: 123STUVWXYZ
FILE3: 123ABCDABCD
FILE4: 123WXYZWXYZ
OUTPUT: 123ABUVCDXY (matching key+ some fields from every file)
Joining 2 files based on m matching key can be done either using SORTJOIN or SPLICE operators. But I am not sure how we can we achieve when multiple files are fed as input for a JCL step and we need to join them based on matching key.
Is this possible in a single JCL step using ICETOOL (or) this is only possible in multiple steps using of either SORTJOIN or SPLICE?
Please advise.
I have got in a new requirement, where in multiple files need to be scanned for a common key across them and if found, then we need to reformat the matched key records from multiple files.
INPUT:
FILE1: 123ABCDEFGH
FILE2: 123STUVWXYZ
FILE3: 123ABCDABCD
FILE4: 123WXYZWXYZ
OUTPUT: 123ABUVCDXY (matching key+ some fields from every file)
Joining 2 files based on m matching key can be done either using SORTJOIN or SPLICE operators. But I am not sure how we can we achieve when multiple files are fed as input for a JCL step and we need to join them based on matching key.
Is this possible in a single JCL step using ICETOOL (or) this is only possible in multiple steps using of either SORTJOIN or SPLICE?
Please advise.