How to replicate rows n times based on the key fields, consider two files one having duplicate keys and another one having unique key. I wanted to replicate records in unique file as many records present for that particular key from the duplicate file.
Output should like:
AAA|10 (AAA has 3 recs in the FileA, hence need to replicate 3 times)
BBB|12 (BBB has only 1 record in FileA)
CCC|09 (CCC has 2 records in FileA)
Joined: 22 Apr 2006 Posts: 6258 Location: Mumbai, India
I would like to "move" this topic to JCL part of the Froum until we "discover" what sort of solution (COBOL, SyncSort or DFSORT) he is looking for; as on homepage having this post titled as "Latest News: How to replicate rows n times based on the key" seems funny . . .
I wanted to place my query in JCL part using DFSORT. Actually i forgot to mention it in my question.. sorry for the inconvenience caused and as Dick mentioned it is for my Job requirement only.
Please kindly help me