Skip to Content

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

Multiply

Hi

I hwve problem in the following code. I am trying to multiply IT_DETAIL-DMBTR (value is 10,000) to -1. But output is 0 instead of -10,000.

Pls help me

ELSEIF  IT_DETAIL-BLART = 'SA' and IT_DETAIL-SHKZG = 'H'.  " AND it_detail-sgtxt(2) = 'DR'.   
 IT_SUM-MACHINE = ( IT_DETAIL-DMBTR ) * ( -1 ).

Tags:
Former Member
Former Member replied

Hello Kumar

Assuming that IT_SUM-MACHINE allows for negative values (do we know???) then you may try another calculation:

IT_SUM-MACHINE = 0.
IT_SUM-MACHINE = IT_SUM-MACHINE - IT_DETAIL-DMBTR.

However, I assume that the problem lies in the type definition of MACHINE.

Regards

Uwe

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question