Hi All,
Iam using ebcdic() function to convert the below input data's from Ascii to Ebcdic format, but the function is not converting the data as required.
Iam passing the input data ebcdic(sign&Deci data) this throws data truncation warning in spite of givign datalength as 7.And for ebcdic(sign data) its not converting as required.
src(odbc)-------->Trm--------->seq file(fixed width.dat file)
scenario || Input data || MF datatype || start || end || MF data length
sign data || +12345 || S9(5) || 1 || 5 || 5
sign data || -00123 || S9(5) || 1 || 5 || 5
sign&Deci|| +12345.12|| S9(5)V9(2) || 6 || 12 || 7
sign&Deci|| -12342.12 || S9(5)V9(2) || 13 || 19 || 7
Note: || are used to seperate
Please suggest me if any code correction to be made in the job/transf to get desired result.
how to convert ascii to EBCDIC format
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 26
- Joined: Tue Dec 18, 2007 6:31 am
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
In DataStage server, in which all data are treated as character strings, S9(5)V99 requires nine character positions, not seven; one for the sign character, seven for the digits and one for the decimal placeholder character.
Similarly, S9(5) requires six character positions; one for the sign and five for the digits.
Similarly, S9(5) requires six character positions; one for the sign and five for the digits.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 26
- Joined: Tue Dec 18, 2007 6:31 am
Hi Craig,
we cann't use CFF stage in the target stage. It can only be used as the source stage and i need to convert ascii data to MF data. I got to know that Ebcdic() function cann't be used to convert signed integer and signed decimal to MF code.Please help me if any routine or code has to be written to convert to signed decimal and signed integer to MF data.
Thanks in advance
Harish
we cann't use CFF stage in the target stage. It can only be used as the source stage and i need to convert ascii data to MF data. I got to know that Ebcdic() function cann't be used to convert signed integer and signed decimal to MF code.Please help me if any routine or code has to be written to convert to signed decimal and signed integer to MF data.
Thanks in advance
Harish