Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

SPACE problem again...

Former Member
0 Likes
478

Hi there...

I need to insert SPACE while concatinating a few strings. i tried to hard code SPACE, but could not succeed. now i hav assigned space to a string type variable (str4), but stil nothings happening. can someone help. the code i hav is as follows.

str4 = ' '.

SPLIT str2 AT ' ' INTO str2 str3.

CONCATENATE str1 '+0(' str2 ')' str4 ' ' str3 ' "Unicode Compatible'

INTO v_pgm_line.

regards

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
460

Hi,

Use RESPECTING BLANKS addition of CONCATENATE to achieve your requirement.

See F1 help for RESPECTING BLANKS for example code.

Regards

Karthik D

4 REPLIES 4
Read only

Former Member
0 Likes
460

CONCATENATE str1 '+0(' str2 ')' str4 ' ' str3 INTO v_pgm_line SEPARATED BY SPACE.

Read only

Former Member
0 Likes
461

Hi,

Use RESPECTING BLANKS addition of CONCATENATE to achieve your requirement.

See F1 help for RESPECTING BLANKS for example code.

Regards

Karthik D

Read only

Former Member
0 Likes
460

try with more sapce...

CONCATENATE str1 '+0(' str2 ')' str4 ' ' str3 INTO v_pgm_line SEPARATED BY SPACE.

Read only

rainer_hbenthal
Active Contributor
0 Likes
460

>

> CONCATENATE str1 '+0(' str2 ')' str4 ' ' str3 ' "Unicode Compatible'

> INTO v_pgm_line.

> regards

Use strings instead of char. The difference is the apostrophe against back quotes.


CONCATENATE str1 `+0(` str2 `)` str4 ` ` str3 INTO v_pgm_line.