Chris
2005-08-31 19:11:52 UTC
Few Issues I'm running into w/VARCHAR and RPG.
Trying to %SUBST on a VARCHAR column in a table. IE.
%Subst(VARCHARFLD:1:15). It bombs, then after a little reading I found
out why (stores the length). So, I thought I could convert it to Char
IE, %CHAR(VARCHARFLD), the Compiler says no. So then I tried the
compiler option, CVTOPT(*VARCHAR). %SUBST worked, but when I tried to
update the DB Table, I received a data mapping error.
What I'm looking for is a way to convert the VARCHAR to a CHAR so I
can do SUBST. Am I missing something? V5R3 If it helps.
Tx
Chris
Trying to %SUBST on a VARCHAR column in a table. IE.
%Subst(VARCHARFLD:1:15). It bombs, then after a little reading I found
out why (stores the length). So, I thought I could convert it to Char
IE, %CHAR(VARCHARFLD), the Compiler says no. So then I tried the
compiler option, CVTOPT(*VARCHAR). %SUBST worked, but when I tried to
update the DB Table, I received a data mapping error.
What I'm looking for is a way to convert the VARCHAR to a CHAR so I
can do SUBST. Am I missing something? V5R3 If it helps.
Tx
Chris