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

translate

Former Member
0 Likes
690

Hello,

The table t_zrs06 contains a field ZZSTOCK (TYPE :INT ) whose value

was 59.

I used the following translate statement

TRANSLATE t_zrs06 USING '; '.

It is coverting the value of ZZSTOCK from 59 to 32.

Please let me know your inputs.

Points will be rewarded for useful answers.

Thanks.

Ramya

Hello,

The table t_zrs06 contains a field ZZSTOCK (TYPE :INT ) whose value

was 59.

I used the following translate statement

TRANSLATE t_zrs06 USING '; '.

It is coverting the value of ZZSTOCK from 59 to 32.

Please let me know your inputs.

Points will be rewarded for useful answers.

Thanks.

Ramya

5 REPLIES 5
Read only

JozsefSzikszai
Active Contributor
0 Likes
669

hi Ramya,

it does not make much sense to use the TRANSLATE statement on integer value... What do you want to achieve?

ec

Read only

0 Likes
669

Hi Ramya & Eric and everyone,

I agree with Eric: it doesn't make sense to use TRANSLATE into a non-char-like field.

Moreover, I recommend to do this replace line-by-line, that is:

LOOP AT itab.

TRANSLATE ...

" ...or some command to change the contents of the field

MODIFY itab.

ENDLOOP.

I hope this helps. Best regards,

Alvaro

Read only

former_member386202
Active Contributor
0 Likes
669

Hi,

Use REPLACE Statement

DATA text TYPE string VALUE '-uu-'.

REPLACE ALL OCCURRENCES OF REGEX 'u*' IN text WITH 'x'.

Regards,

PRashant

Read only

kesavadas_thekkillath
Active Contributor
0 Likes
669

whatz u r excat question...???

Read only

Former Member
0 Likes
669

Hi Ramya,

What you want to do acutally??? You cannot use translate on non-chacter fields.... Translate is used to convert lower to upper case vice versa. So please clear your question. What u want to achieve? What you are asking to solve?? it is not clear in your question.

Regards,

sunil kairam.