45 pts.
 Opcode remove space in RPG/400 (RPGIII)
in RPG IV --> Trim

in RPG III --> ?

Ex 

var1 length=10  var2 length=10

var1 = 'AAA'

var2 = 'BBB'

var1  cat  var2  ---> 'AAA       BBB       '   

i want --> 'AAABBB'



Software/Hardware used:
ASKED: September 9, 2010  3:26 AM
UPDATED: September 9, 2010  12:45 PM
  Help
 Approved Answer - Chosen by TomLiotta

C STR1 CAT STR2:0 TEMP P

The :0 indcates on factor 2 makes this act like
TEMP = %rtrim(STR1) + STR2
It doesn't use the trailing spaces on STR1.
It Cats STR2 on, leading spaced and all.
The P will fill out the result with spaces.

http://publib.boulder.ibm.com/infocenter/iadthelp/v7r0/index.jsp?topic=/com.ibm.etools.iseries.langref.doc/evferlsh269.htm

Phil

ANSWERED:  Sep 9, 2010  10:25 AM (GMT)  by TomLiotta

 
Other Answers:
Last Wiki Answer Submitted:  June 27, 2012  7:34 am  by    0 pts.
Latest Answer Wiki Contributors: 
To see other answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _