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

Split at

Former Member
0 Likes
413

Hi all,

I am trying to split a field into its decimal and integer part but for some reason it just does want to split it.

Here's my code:

DATA: W_PALLET(17) TYPE C,

W_FACTOR(17) TYPE C,

W_INT(13) TYPE C,

W_INT1(13) TYPE C,

W_INT2(13) TYPE C,

W_DEC(3) TYPE C,

w_dec2(3) type c,

W_PALLETS(17) TYPE C.

MOVE IT_OUTTAB-REQ_QTY_PAL TO W_PALLET.

SPLIT W_PALLET AT '.' INTO W_INT W_DEC .

MOVE '000' TO W_INT1.

CONCATENATE W_INT1 W_DEC INTO W_PALLET SEPARATED BY '.'.

W_FACTOR = W_PALLET / ( ROUNDFAC / 100 ).

SPLIT W_FACTOR AT '.' INTO W_INT2 W_DEC2.

ADD 1 TO W_INT2.

W_PALLETS = W_INT2 * ( ROUNDFAC / 100 ).

IT_OUTTAB-ROUNDED_PAL = W_PALLETS + W_INT.

Thanx!

2 REPLIES 2
Read only

Former Member
0 Likes
395

its the second 'split at' that is not working...

Read only

Former Member
0 Likes
395

hi! i found my answer!

thanx!