View previous topic :: View next topic
|
Author |
Message |
Hima1985
New User
Joined: 17 Apr 2009 Posts: 70 Location: India
|
|
|
|
Some how from other applications I have received a file with numeric fields alligend to left, can you please assist in assigning that field to left
file format is FB and rec length is 100
Field starting position is 5th byte and field length is 8 bytes
Code: |
123 50.00. xyz apple
124 50.00. mno apple
124 100.00. Pqr apple
125 1000.00. Abc apple
126 10000.00 mno apple
127 100000.00abc apple |
I need this in below format
Code: |
123. 50.00xyz apple
124. 50.00mno apple
124. 100.00Pqr apple
125. 1000.00Abc apple
126. 10000.00mno apple
127 100000.00abc apple |
Can we achieve this with sort? |
|
Back to top |
|
|
hailashwin
New User
Joined: 16 Oct 2008 Posts: 74 Location: Boston
|
|
|
|
Hi,
I think the numeric field is 9 bytes and this should work..
Code: |
//SYSIN DD *
OPTION COPY
OUTREC FIELDS=(1,4,5,9,JFY=(SHIFT=RIGHT),14,9)
//*
|
Thanks,
Ashwin |
|
Back to top |
|
|
Hima1985
New User
Joined: 17 Apr 2009 Posts: 70 Location: India
|
|
|
|
Jfy is giving syntax error .. Might be missing some pti's of my sort.. Any other solutios please? |
|
Back to top |
|
|
Skolusu
Senior Member
Joined: 07 Dec 2007 Posts: 2205 Location: San Jose
|
|
|
|
Hima1985 wrote: |
Jfy is giving syntax error .. Might be missing some pti's of my sort.. Any other solutios please? |
Hima1985,
You need to show us the syntax error you are getting. And for the record JFY function has been a part of UK90007 which was first available in April, 2006. If your shop does not have that PTF , then you probably are running an unsupported , out of service version of DFSORT. |
|
Back to top |
|
|
|