View previous topic :: View next topic
|
Author |
Message |
loverj24
New User
Joined: 05 Jul 2007 Posts: 16 Location: bangalore
|
|
|
|
Hi,
I have a FB file whose length is 297. At 279 position records are like this
Code: |
0000000 Col 218 297
Scroll ===> CSR
--8----+----9----+--
********************
|1234 0882|011010887
|1234 0882|011010884
| 0882|011010878
| 0882|011010888
| 2218|011009928
| 1234|011001320
|1234 0887|011011914
| 0887|011011520
| 0611|011013015
******************** |
I need the out put like
Code: |
|1234 0882|011010887
|1234 0882|011010884
|0882|011010878
|0882|011010888
|2218|011009928
|1234|011001320
|1234 0887|011011914
|0887|011011520
|0611|011013015
******************** |
I need to remove the spaces that are of 4 bytes at the 279th position.
Please help me regarding this |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Here's a DFSORT job that will do what you asked for:
Code: |
//S1 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=... input file (FB/297)
//SORTOUT DD DSN=... output file (FB/297)
//SYSIN DD *
OPTION COPY
INREC IFTHEN=(WHEN=(279,1,CH,EQ,C' '),
OVERLAY=(279:279,19,JFY=(SHIFT=LEFT)))
/*
|
|
|
Back to top |
|
|
Aaru
Senior Member
Joined: 03 Jul 2007 Posts: 1287 Location: Chennai, India
|
|
|
|
Frank,
Quote: |
spaces that are of 4 bytes at the 279th position.
|
As OP wanted to check for 4 bytes spaces, we can very well check for 4 spaces instead of one. |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Checking for 1 space will work for the example records shown, but the OP can certainly check for 4 spaces if necessary with
|
|
Back to top |
|
|
Aaru
Senior Member
Joined: 03 Jul 2007 Posts: 1287 Location: Chennai, India
|
|
|
|
Quote: |
Checking for 1 space will work for the example records shown, but the OP can certainly check for 4 spaces if necessary with
|
Thanks Frank. |
|
Back to top |
|
|
|