Skip to Content
0

how to convert 0.000 values of packed data type into space('')

Dec 16, 2017 at 05:56 AM

55

avatar image
Former Member

DATA : gv_index TYPE i.

BEGIN OF ty_tab_slab,

end_cut TYPE p DECIMALS 3,

BEGIN OF ty_tab_gr_slab

LOOP AT t_tab_slab INTO w_tab_slab.
gv_index = sy-tabix.
IF w_tab_slab-end_cut = '0.000'.
w_tab_slab-end_cut = space.
ENDIF.
MODIFY t_tab_slab FROM w_tab_slab TRANSPORTING end_cut.
CLEAR : w_tab_slab.
ENDLOOP.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Sandra Rossi Dec 16, 2017 at 02:00 PM
0

You can't. Type P (also known as BCD in information systems) can contain only decimal digits and sign (and the number of digits before and after the decimal point are defined statically in the declaration of the variable).

Share
10 |10000 characters needed characters left characters exceeded