Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

ABAP Unicode assignment question

I want to replace # characters in a string with space.

I hav a 472 unicode enabled system.

Single field <keydata>+66

Field contents ####### 0000201040 WI 01 000001

Type C

Length 31

Output length 31

Decimal places 0

these # characters have to be cleaned out in this string.

I tried REPLACE ALL OCCURRENCES OF '#' IN <keydata>+66(*) WITH space. without any success.

I tried this code snippet also without any success.

data: t1 type i value 66,

t2 type i value 1,

c_hash type x value '#'.

field-symbols : <fs> type any .

assign <keydata>+t1(1) to <fs> casting type x.

while ( <fs> eq c_hash ).

<keydata>+t1(1) = space.

t1 = t1 + 1.

assign <keydata>+t1(1) to <fs> casting type x.

endwhile.

<keydata>+t1(1) = space.

Please suggest what could be the solution.

Thanks,

Tags:
replied

Hi Parul,

in debug put the variable in the fields area at the bottom and click the magnifying glass..this switches to hex mode.

0 View this answer in context

Helpful Answer

by
Not what you were looking for? View more on this topic or Ask a question