Vous êtes sur la page 1sur 1

*&---------------------------------------------------------------------*

*& Subroutine Pool


ZCALCULATE
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*

subroutine pls remember its a subroutine in se38


PROGRAM

ZCALCULATE.

FORM CALCULATE TABLES intab STRUCTURE itcsy


outtab STRUCTURE itcsy.
DATA: amountbf TYPE MSEG-DMBTR,
amountaf TYPE MSEG-DMBTR.
READ TABLE intab with KEY 'MSEG-DMBTR'.
CHECK sy-subrc = 0.
amountbf = intab-value.
amountaf = amountaf + amountbf.
READ TABLE outtab with KEY 'AMOUNT'.
CHECK sy-subrc = 0.
write amountaf to outtab-value.
modify outtab INDEX sy-index.
ENDFORM.

Vous aimerez peut-être aussi