dburt16
Member
Installed on new server Oracle (JDE) databse as unicode 13488
20 years worth of RPGILE developed for WORLD and E1 SBCS will not compile over new Oracle E1 databases without
a lot of coding fixes.
New server is OS 7.2 system (same as one with the SBCS database).
According to documentation I read, PTFs (V5.3) a long time ago shold have fixed the conversion problem
between CHAR, UCS2 and Graphic types so that you would not have to wrap a %graphic() or %UCS2 around
fields you are using in comparisons or to make assignment.
The purpose of the PTFs were supposed to be to minimalize coding when using RPGILE and unicode DBs.
But. I still see the same issues that the PTFs were supposed to address. I have rarely had to worry about
DBCS programming and I may simply be doing something wrong.
These type of statements stop the compile with a "data type mismatch" or "parameter nn is wrong data type. ":
***BAD***
/free
if myCharFld = jdeField;
P=%scan('ABC':jdeField);
jdeField=%xlate(lower:upper:jdeField);
myNumber=%dec(jdeField:8:0);
/end-free
**FIXED***
if %ucs2(myCharFld) = jdeField;
P=%scan(%ucs2('ABC':jdeField);
JdeField = %xlate(%ucs2(lower):%ucs2(upper):jdeField);
myNumber = %dec(%trim(%ucs2(jdeField)));
Thank you in advance for any help you have to offer.
20 years worth of RPGILE developed for WORLD and E1 SBCS will not compile over new Oracle E1 databases without
a lot of coding fixes.
New server is OS 7.2 system (same as one with the SBCS database).
According to documentation I read, PTFs (V5.3) a long time ago shold have fixed the conversion problem
between CHAR, UCS2 and Graphic types so that you would not have to wrap a %graphic() or %UCS2 around
fields you are using in comparisons or to make assignment.
The purpose of the PTFs were supposed to be to minimalize coding when using RPGILE and unicode DBs.
But. I still see the same issues that the PTFs were supposed to address. I have rarely had to worry about
DBCS programming and I may simply be doing something wrong.
These type of statements stop the compile with a "data type mismatch" or "parameter nn is wrong data type. ":
***BAD***
/free
if myCharFld = jdeField;
P=%scan('ABC':jdeField);
jdeField=%xlate(lower:upper:jdeField);
myNumber=%dec(jdeField:8:0);
/end-free
**FIXED***
if %ucs2(myCharFld) = jdeField;
P=%scan(%ucs2('ABC':jdeField);
JdeField = %xlate(%ucs2(lower):%ucs2(upper):jdeField);
myNumber = %dec(%trim(%ucs2(jdeField)));
Thank you in advance for any help you have to offer.