View previous topic :: View next topic
|
Author |
Message |
RM0C13920
New User
Joined: 16 Dec 2009 Posts: 6 Location: bbbd
|
|
|
|
The two files will be merged and sorted into account number sequence, with a Header and Trailer record created from the latest generation of the file, with the record count updated to show the new total.
account number starts from 2 byte upto 14 byte length
Please let me know the how to do this by Icetool or Sort
Finally I need to merge two files GDG with header and trailor from Latest version and in trailor count should be new total number records.
and also It should be account number sequence which starts from 3 byte till length of 14 bytes. |
|
Back to top |
|
|
daveporcelan
Active Member
Joined: 01 Dec 2006 Posts: 792 Location: Pennsylvania
|
|
|
|
Could you please be a little more vauge with your specifications?
This is way too much detail. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
Please let me know the how to do this by Icetool or Sort |
You need to show some sample input, the output you want from that sample input, and the explain the rules for getting from the input to the output. Mention the recfm and lrecl of the files. |
|
Back to top |
|
|
RM0C13920
New User
Joined: 16 Dec 2009 Posts: 6 Location: bbbd
|
|
|
|
gdg1
0120100406hdr
1030100012345678
1030100012345677
99002tlr
GdG2
0120100405hdr
1030100012345289
1030100012345680
1030100012348680
99003tlr
i need to merge with record like thT and bold is trailor count
o/p file
0120100406hdr
1030100012345289
1030100012345677
1030100012345678
1030100012345680
1030100012348680
99005tlr (trailor count is latest and header and trailor is from latest version and sequenced by accout number |
|
Back to top |
|
|
Skolusu
Senior Member
Joined: 07 Dec 2007 Posts: 2205 Location: San Jose
|
|
|
|
RM0C13920,
Use the following DFSORT JCL
Code: |
//STEP0100 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=your.gdg.gen(-1),DISP=SHR
// DD DSN=your.gdg.gen(-0),DISP=SHR
//SORTOUT DD SYSOUT=*
//SYSIN DD *
OMIT COND=(1,1,CH,EQ,C'9')
SORT FIELDS=(1,15,CH,A),EQUALS
OUTFIL STARTREC=2,REMOVECC,
TRAILER1=('99',COUNT-1=(M11,LENGTH=3),'TLR')
//* |
|
|
Back to top |
|
|
RM0C13920
New User
Joined: 16 Dec 2009 Posts: 6 Location: bbbd
|
|
|
|
Thanks alot..
Its working |
|
Back to top |
|
|
|