View previous topic :: View next topic |
Author |
Message |
rameshm Beginner
Joined: 05 Jan 2006 Posts: 1 Topics: 1 Location: chennai
|
Posted: Tue Oct 27, 2009 5:57 am Post subject: Need help in SQZ |
|
|
there is a requirement as follows (lrecl=80, FB)
input Code: |
aaaaa|000345|000000| bbbb^^^^|^^^^|nnnnnn
|
output required is
Code: |
aaaaa|000345||bbbb^^^^||nnnnnn
|
i.e., only zeros and spaces found between '|' needs to be removed and not the trailing or leading zeros&spaces between '|'
important---> ^ represents spaces or blanks (for clear notification i have used this notation )
could anyone help out please?
Thanks
RameshM |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12376 Topics: 75 Location: San Jose
|
Posted: Tue Oct 27, 2009 10:27 am Post subject: |
|
|
rameshm,
You can use the following DFSORT JCL to get the desired results
Code: |
//STEP0100 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD *
AAAAA|000345|000000| BBBB | |NNNNNN
//SORTOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=COPY
INREC FINDREP=(IN=(C'| |',C'|000000|'),OUT=C'||')
/* |
_________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
|
|
|