View previous topic :: View next topic
|
Author |
Message |
ashok4u_it
New User
Joined: 12 Mar 2008 Posts: 53 Location: Chennai
|
|
|
|
Hi,
Can anyone please help me to Eliminate Duplicate values along with the Original Entry using DFSORT. Please I dont want this to be done using ICETOOL.
Ex:- I am having a dataset with following Entries.
XXXXX
YYYYYY
XXXXX
ZZZZZ
AAAAA
YYYYYY
YYYYYY
My output shud contain only the unique values as shown below.
ZZZZZZ
AAAAAA
Can anyone please provide a DFSORT code for this scenario.
Regards
Ashok. |
|
Back to top |
|
|
denis.dhimitri
New User
Joined: 25 Mar 2008 Posts: 14 Location: milan, italy
|
|
|
|
Well, you can use an ICETOOL card with the NODUPS option
//TOOLIN DD *
SELECT FROM(INP) TO(OUT) ON(1,6,CH) NODUPS
Denis |
|
Back to top |
|
|
ashok4u_it
New User
Joined: 12 Mar 2008 Posts: 53 Location: Chennai
|
|
|
|
Hi Denis,
I know this can be done in ICETOOL using NODUPS option. But, thats the challenge here, it should be done without ICETOOL. Here, in my office, ICETOOL cannot be used in production region.
Regards
Ashok. |
|
Back to top |
|
|
denis.dhimitri
New User
Joined: 25 Mar 2008 Posts: 14 Location: milan, italy
|
|
|
|
Sorry Ashok,
That's was what I use mostly in these cases. For another way of eliminating DUPS with ICEMAN or SORT is better to ask directly to Mr. Yaeger. I'm sure if he has time will resolve your problem.
Regards
Denis |
|
Back to top |
|
|
ashok4u_it
New User
Joined: 12 Mar 2008 Posts: 53 Location: Chennai
|
|
|
|
Hi,
Mr.Dennis - Thanks for your way. But no need of sorry here.
Mr.Yaeger. Could you please help on this case. Is there any other way using JCL (Excluding ICETOOL).
Anyone, please throw your lights.
Regards
Ashok. |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Ashok,
You can use a DFSORT job like this to do what you asked for:
Code: |
//S1 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD *
XXXXX
YYYYYY
XXXXX
ZZZZZ
AAAAA
YYYYYY
YYYYYY
/*
//SORTOUT DD DSN=&&T1,UNIT=SYSDA,SPACE=(CYL,(5,5)),DISP=(,PASS)
//SYSIN DD *
INREC OVERLAY=(81:C'00000001',89:SEQNUM,8,ZD)
SORT FIELDS=(1,10,CH,A)
SUM FIELDS=(81,8,ZD)
OUTFIL INCLUDE=(81,8,ZD,EQ,+1)
/*
//S2 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=&&T1,DISP=(OLD,PASS)
//SORTOUT DD DSN=... output file (FB/80)
//SYSIN DD *
SORT FIELDS=(89,8,ZD,A)
OUTREC BUILD=(1,80)
/*
|
|
|
Back to top |
|
|
ashok4u_it
New User
Joined: 12 Mar 2008 Posts: 53 Location: Chennai
|
|
|
|
Hi Frank,
Your code worked fine.
Thanks a lot for your immediate response.
Regards
Ashok. |
|
Back to top |
|
|
|