View previous topic :: View next topic
|
Author |
Message |
AJAYREDDY
New User
Joined: 17 Feb 2007 Posts: 52 Location: USA
|
|
|
|
I am trying to convert the amounts below from +ve to -ve and vise versa. The file is total FB 28 bytes. I am using below mulitply sort parameters. But I am getting Field outside range error. The dollar amount is ZD position 15 length 10.
Please let me know what is wrong with this statement.
Code: |
SYSIN :
OPTION COPY
INREC BUILD=(-1,MUL,15,24,SFF,ZD,LENGTH=10)
|
Code: |
WER276B SYSDIAG= 8796, 1633333, 1633333, 3358275
WER164B 5,668K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,
WER164B 0 BYTES RESERVE REQUESTED, 1,004K BYTES USED
WER146B 20K BYTES OF EMERGENCY SPACE ALLOCATED
WER108I SORTIN : RECFM=FB ; LRECL= 28; BLKSIZE= 27972
WER073I SORTIN : DSNAME=GGG.AAA.RRR.MMM.
WER230A INREC FIELD OUTSIDE RANGE
|
The sample file data.
Code: |
ABCD2AA 5 00000672841212
LMNO2AA 6 00000672841212
RRRR2ABS 4 00000132961212
ABCD2ABS 5 000035714J1212
LMNO2ABS 6 000034384N1212
RRRR2AGR 4 00002022591212
ABCD2AGR 5 00229656141212
LMNO2AGR 6 00231678731212
ABCD2AKMD5 00001474221212
LMNO2AKMD6 00001474221212 |
|
|
Back to top |
|
|
AJAYREDDY
New User
Joined: 17 Feb 2007 Posts: 52 Location: USA
|
|
|
|
I think now I got it. I should use below INREC parameters.
Code: |
//SYSIN DD *
OPTION COPY
INREC OVERLAY=(15:15,10,ZD,MUL,-1,TO=ZD,LENGTH=10)
|
The one that I used before maybe works from position 1 only. |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
You have SyncSort (WER... messages). SyncSort questions are in the JCL part of the forum.
Instead of multiplying by -1, you could always subtract from zero. |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
Quote: |
The one that I used before maybe works from position 1 only. |
Your input file is of LRECL=28, however using this
Code: |
INREC BUILD=(-1,MUL,15,24,SFF,ZD,LENGTH=10) |
you're going beyond that and so the obvious error:
Code: |
WER230A INREC FIELD OUTSIDE RANGE |
|
|
Back to top |
|
|
|