View previous topic :: View next topic
|
Author |
Message |
balukanna
New User
Joined: 09 Apr 2008 Posts: 41 Location: USA
|
|
|
|
Hi..
I need to change a field length as well as the file length,
My file has the layout as given below,
Field1 - 1-20 (length20)
Field2 - 21-50 (length 30)
Field3 - 51-100(length 50)
Field4 - 101-180(length 80)
Total file length is 180.
Need an output like
Field1 - 1-20 (length20)
Field2 - 21-50 (length 30)
Field3 - 51-90(length 40)
Field4 - 91-145(length 55)
Total file length is 145.
_________
Thanks
Balukanna |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Assuming you want the first 40 bytes from Field3 and the first 55 bytes from field4, you can use a DFSORT job like this:
Code: |
//S1 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=... input file (FB/180)
//SORTOUT DD DSN=... output file (FB/145)
//SYSIN DD *
OPTION COPY
INREC BUILD=(1,90,101,55)
/*
|
|
|
Back to top |
|
|
balukanna
New User
Joined: 09 Apr 2008 Posts: 41 Location: USA
|
|
|
|
Thanks Frank..
Its working fine.. |
|
Back to top |
|
|
|