I have sort card where i am moving the this-year-* data fields to last-year* data fields and reset this this-year data fields to zero and i am seeing the issue could be in reset the value zero to this-year data fields and i am not sure why it is causing the issue .
Joined: 06 Jun 2008 Posts: 8696 Location: Dubuque, Iowa, USA
Did you look up the reason code associated with the ICE126A message up in the manual? If not, why not start there -- ESPECIALLY since you did not bother to post that critical detail?
Did you look up the reason code associated with the ICE126A message up in the manual? If not, why not start there -- ESPECIALLY since you did not bother to post that critical detail?
Hi Robert,
When i read thru the error description it is found that data that is passed which is inconsistent with the format that is defined . But if if you see i have passed the data correctly according the format defined and also i have tried to pass the value for PD like X'000000000000000C' and again i got the same error .
error i got from my job
Code:
ICE126A 2 INCONSISTENT REFORMATTING FOR *OUTREC : REASON CODE
04 , IF THEN 0
Did you look up the reason code associated with the ICE126A message up in the manual? If not, why not start there -- ESPECIALLY since you did not bother to post that critical detail?
Hi Robert,
I am sorry, i apologize for not putting the error message in my initial post.
Joined: 06 Jun 2008 Posts: 8696 Location: Dubuque, Iowa, USA
Quote:
it is found that data that is passed which is inconsistent with the format that is defined
Actually, the 04 reason code does not mean this at all. From the messages manual:
Quote:
4.A column overlapped the previous output field in the reformatted record.
Example (fixed-length input):
INREC IFTHEN=(WHEN=INIT,
BUILD=(81:SEQNUM,8,ZD)),
IFTHEN=(WHEN=(81,8,ZD,EQ,+1),
BUILD=(3,20,20:C'ABC'))
You read the first paragraph in the error manual, without looking at the reason code (or not understanding what the reason code means) and went off on a wild goose chase for inconsistent formats when your problem was something else entirely.
I took your SORT statements and rearranged them as
so there is no overlapping, and the code worked and produced an output data set. If you read the manual on the OUTREC statement, as I did, you will find that any gaps you leave in your FIELDS will be filled with spaces so you need to put the fields in ascending column sequence when coding it.
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
First don't use FIELDS use BUILD.
Second, don't use columns unless you need them, which you don't here.
BUILD creates a new record, sourced from the original, so there is no need to attempt to reference fields out of order. Your code fails exactly for the reason specified by Robert.
Indeed, for this task, OVERLAY is better, where you would use columns and be concerned with the order. It uses the current record and only changes data specified in the statement.
Second, don't use columns unless you need them, which you don't here.
BUILD creates a new record, sourced from the original, so there is no need to attempt to reference fields out of order. Your code fails exactly for the reason specified by Robert.
Indeed, for this task, OVERLAY is better, where you would use columns and be concerned with the order. It uses the current record and only changes data specified in the statement.
Thanks Bill for your advise ,i have used BUILD instead of Fields.
it is found that data that is passed which is inconsistent with the format that is defined
Actually, the 04 reason code does not mean this at all. From the messages manual:
Quote:
4.A column overlapped the previous output field in the reformatted record.
Example (fixed-length input):
INREC IFTHEN=(WHEN=INIT,
BUILD=(81:SEQNUM,8,ZD)),
IFTHEN=(WHEN=(81,8,ZD,EQ,+1),
BUILD=(3,20,20:C'ABC'))
You read the first paragraph in the error manual, without looking at the reason code (or not understanding what the reason code means) and went off on a wild goose chase for inconsistent formats when your problem was something else entirely.
I took your SORT statements and rearranged them as
so there is no overlapping, and the code worked and produced an output data set. If you read the manual on the OUTREC statement, as I did, you will find that any gaps you leave in your FIELDS will be filled with spaces so you need to put the fields in ascending column sequence when coding it.
Thanks Robert for your Quick Help and as Bill suggested i have used OUTREC BUILD instead of OUTREC FIELDS.