View previous topic :: View next topic
|
Author |
Message |
dharmaraok
New User
Joined: 10 Mar 2011 Posts: 45 Location: india
|
|
|
|
I have field in a file having comp-3 value 2017. I need to convert this field with 2018. I have written Overlay in SORT card but it is not working.
INREC OVERLAY=(85:X'2018')
Please help me how to conver the field by using sort |
|
Back to top |
|
|
Garry Carroll
Senior Member
Joined: 08 May 2006 Posts: 1193 Location: Dublin, Ireland
|
|
|
|
Wouldn't a COMP-3 field have a sign (e.g. X'02017C' ) ? And wouldn't you want to replace that with X'02018C' ?
And are you going to change every record in the dataset, even if it has a value other than 2017 ?
What have you tried and with what result?
Garry |
|
Back to top |
|
|
sergeyken
Senior Member
Joined: 29 Apr 2008 Posts: 2010 Location: USA
|
|
|
|
dharmaraok wrote: |
I have field in a file having comp-3 value 2017. I need to convert this field with 2018. I have written Overlay in SORT card but it is not working.
INREC OVERLAY=(85:X'2018')
Please help me how to conver the field by using sort |
Please demonstrate
1) real code; at least - FULL set of your SORT statements
2) example of input data, with recognizable offset, and hex image
3) actual output data, with recognizable offset, and hex image
Without this info, the answer to your question would be: please, do everything right, and the result should not be wrong. |
|
Back to top |
|
|
sergeyken
Senior Member
Joined: 29 Apr 2008 Posts: 2010 Location: USA
|
|
|
|
dharmaraok wrote: |
I have field in a file having comp-3 value 2017. I need to convert this field with 2018. I have written Overlay in SORT card but it is not working.
INREC OVERLAY=(85:X'2018')
Please help me how to conver the field by using sort |
COMP-3 only exists inside COBOL code. Out of COBOL there is no such thing as COMP-3. Verify your terminology. |
|
Back to top |
|
|
Marso
REXX Moderator
Joined: 13 Mar 2006 Posts: 1353 Location: Israel
|
|
|
|
dharmaraok wrote: |
I have written Overlay in SORT card but it is not working. |
Usually, this sentence is not well received in the forum
What is not working ?
Does it cancel or does it finish with a return code or does it produce an incorrect output ? |
|
Back to top |
|
|
sergeyken
Senior Member
Joined: 29 Apr 2008 Posts: 2010 Location: USA
|
|
|
|
Marso wrote: |
dharmaraok wrote: |
I have written Overlay in SORT card but it is not working. |
Usually, this sentence is not well received in the forum
What is not working ?
Does it cancel or does it finish with a return code or does it produce an incorrect output ? |
...or the computer got fire, and was destroyed completely? |
|
Back to top |
|
|
|