Help in Soring Datasets



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

Help in Soring Datasets

Postby cai_0715 » Thu Oct 07, 2010 9:27 pm

Hi. Im new here. Hope someone could help me.

I want to create a JCL, that would delete duplicates. However, there are 2 conditions:

First validation would be, checking of duplicates for column 6 - 9.

Second, if column 6 - 9 is a duplicate, it would check if column 1 - 4 is greater than its duplicate line. If column 1 - 4 is lower, then it would be the line that would be deleted. Im new to JCL, so please bear with my explanation.

Sample:

Input would consist of

123456789
=========
111201010
111101010
111201012
111101011

Output:

123456789
=========
111201010
111101011
111201012

*line 2 would be deleted, since its column 6 - 9 has a duplicate of line 1 Also, its column 1 - 4 has a lower value (1111) compared to the column 1 - 4 (1112) of line 1.

Please, I would really appreciate any feedbacks. Thank you.
cai_0715
 
Posts: 1
Joined: Thu Oct 07, 2010 9:09 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Help in Soring Datasets

 

Re: Help in Soring Datasets

Postby NicC » Thu Oct 07, 2010 10:08 pm

First - JCL cannot do what you want. JCL is an 'interface' between your program and the operating system. It lets the operating system know what resources, files etc, your program needs.

I guess what you are looking for are the sort control cards for a sort solution to your problem in which case this should be posted in one of the sort sections. DO NOT REPOST - someone will move it to the correct place for you but you need to supply the sort product you are using - DFSORT, SYNCSORT, something else.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2690
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisys (almost)
Has thanked: 4 times
Been thanked: 105 times


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post