I have a record with length 323 which is coming from informatica in ASCII.
Of these few fields are to be converted from numeric to packed decimALS.
below are the fields positions which need to be converted into packed decimal and binary respectively to get executed on mainframe.
i could not format the below can some one help me on these.
Thanks for ur suggestion, But when i give first line of code alone, its working but with the whole code its not working i believe there is syntax error in my code may be in formatting as well. Could you please suggust on the same
do You realize that just whining it is not working is only a waste of time for everybody.
if You do not tell the error and post some significant info the chances of getting help are pretty slim.
hi enrico,
below is the error code:
Code:
********************************* TOP OF DATA **********************************
2016
SYSIN :
OPTION COPY 0012000
OUTREC BUILD =(40,11,ZD,TO=PD,LENGTH=6,AND, 0013000
*
51,11,ZD,TO=PD,LENGTH=6,AND, 0014000
*
62,11,ZD,TO=PD,LENGTH=6,AND, 0015000
*
73,11,ZD,TO=PD,LENGTH=6,AND, 0016000
*
148,9,ZD,TO=BI,LENGTH=4,AND, 0017000
*
159,2,ZD,TO=PD,LENGTH=2,AND, 0018000
*
270,11,ZD,TO=PD,LENGTH=6,AND, 0019000
*
281,11,ZD,TO=PD,LENGTH=6,AND, 0020000
*
299,4,ZD,TO=BI,LENGTH=2,AND, 0021000
*
304,9,ZD,TO=BI,LENGTH=4,AND, 0022000
*
313,11,ZD,TO=PD,LENGTH=6) 0023000
*
WER268A OUTREC STATEMENT : SYNTAX ERROR
WER275A NO KEYWORDS FOUND ON CONTROL STATEMENT
WER275A NO KEYWORDS FOUND ON CONTROL STATEMENT
WER275A NO KEYWORDS FOUND ON CONTROL STATEMENT
WER275A NO KEYWORDS FOUND ON CONTROL STATEMENT
WER275A NO KEYWORDS FOUND ON CONTROL STATEMENT
WER275A NO KEYWORDS FOUND ON CONTROL STATEMENT
The below code is working for me but i need to carry out the remaining fields in the output file along with the below fields and reduce the file record length from 323 to 276.
please suggest how to format the remainingg fields. I think the fields other than these will have a change in their positions and how i need to handle this
I just investigated and found that the info which informatica send the data is in edited numeric.here is my analysis:
999999999.99--its taking as 12 bytes, i need to convert this into packed decimal
also few fields are need to be stored in comp which is binary. how to define the input layout for the same???
input fields(data from informatica)----------->outfields
--------------------------------------- ----------
1. numeric-------------------------------------->could read as edited numeric
2. numeric-------------------------------------->need to read as binary.how
---------------------------------------------------to define in mainframe cpy bk
also , please can you suggest how to convert into packed decimal.
is it better to go with a simple cobol program??
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
Show the code that does not work. Did you put LENGTH= on your converted fields?
All I did was show you how to "fill in the gaps" between your fields you want to convert. I cannot know if you have defined your positions correctly, or if you have got the correct lengths for them. I'm not that psychic.
I just investigated and found that the info which informatica send the data is in edited numeric.here is my analysis:
999999999.99--its taking as 12 bytes, i need to convert this into packed decimal
also few fields are need to be stored in comp which is binary. how to define the input layout for the same???
input fields(data from informatica)----------->outfields
--------------------------------------- ----------
1. numeric-------------------------------------->could read as edited numeric
2. numeric-------------------------------------->need to read as binary.how
---------------------------------------------------to define in mainframe cpy bk
also , please can you suggest how to convert into packed decimal.
is it better to go with a simple cobol program??
hi bill,
this is th ebelow code which i have donw with ,
yet i could not get th eoutput then i found that teh data from informatica is in edited numeric format.
Pick a representative part of your data, show some sample records for that and expected output.
With your example, you are only attempting to get the numeric fields on your output. Is that what you want?
Meanwhile, experiment with FS instead of ZD.
Hi bill,
Thanks for ur quick response and help...for now i dont have system..
how ever i can present the data i want
input: +721.99( is in edited numeric)
out put : should be converted into packed decimal and when using file manager the value should be look like above only. I mean +721.99
secondly,
for binary:
data should be converted to s9(4) comp and s9(8) comp.
when i declared the informatica data in numeric to check in file manager i could not see any value coming in. what could be the reason??