Professional Documents
Culture Documents
REPORT zextract_tcs_auswertung.
INITIALIZATION.
*** Store the Name of the SAP System
tp_sysid = sy-sysid.
START-OF-SELECTION.
*** Initial run : Extract data for last 1 year
IF rb_initl EQ abap_true.
CLEAR : tp_date.
CALL FUNCTION 'RP_CALC_DATE_IN_INTERVAL'
EXPORTING
date = sy-datum
days = '00'
months = '00'
signum = '-'
years = '01'
IMPORTING
calc_date = tp_date.
*&---------------------------------------------------------------------*
*& Form GET_DATA
*&---------------------------------------------------------------------*
* Subroutine to execute query and get data
*----------------------------------------------------------------------*
FORM get_data.
IF rb_other NE 'X'.
so_datum-sign = 'I'.
so_datum-option = 'BT'.
so_datum-low = tp_date.
so_datum-high = sy-datum.
APPEND so_datum.
ENDIF.
SUBMIT aqcsch_tcs======tcs_auswertung
WITH sp$00005 IN so_datum[]
EXPORTING LIST TO MEMORY AND RETURN.
ELSE.
WRITE:/ 'No data exists for given selection'(002).
ENDIF.
ENDFORM. " DATA_OUTPUT