View previous topic :: View next topic
|
Author |
Message |
amitc23
New User
Joined: 05 Nov 2014 Posts: 95 Location: India
|
|
|
|
Hi
I am reading a file which has a field x'001c' at position 17. The declaration in the assembler copybook is
AXBCBKNO DS PL2 PROCESS CENTER NUMBER
I am trying to move this (through reference modification) to a field which is defined as 9(5) . How can I structure the move statements so that I can see '00001' in the output field. Do I need some intermediate moves.
Thanks a lot |
|
Back to top |
|
|
Terry Heinze
JCL Moderator
Joined: 14 Jul 2008 Posts: 1249 Location: Richfield, MN, USA
|
|
|
|
You shouldn't need reference modification. If the source field is defined as S999 COMP-3 in COBOL and the destination field is 9(5), a simple elementary move should do it. |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
Yes, reference-modification would be an odd and unworkable way to do that. Define the field as COMP-3 or PACKED-DECIMAL PIC S999 and just MOVE. Give the data a good name (sending and receiving fields) and you never know, someone may be able to follow your code. |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
This is an example of having a little bit of Assembler knowledge and it would go a long way.... |
|
Back to top |
|
|
|