When inserting or updating a Long Character field in Peoplesoft using peoplecode, standalone SQL or Application Engine SQL, if the target string to be inserted
happens to be more than 254 characters long, the program results in an error saying "String or Binary data would be truncated" and the insert/update fails.
This issue can be resolved by using the %TextIn function as shown below.
UPDATE RECORDNAME SET XLATLONGNAME = %TEXTIN(:1)
INSERT INTO RECORDNAME VALUES(:1,:2,%TEXTIN(:3))
In the above example, :1 and :3 are the target long string that is to be inserted in the Long character field.
-- This tip has been provided by Sumanta K Sen.
Sumanta K Sen1/India/IBM.