SAPF020 is a standard Executable ABAP Report available within your SAP system (depending on your version and release level). It is used for This program resets transaction data in a company code, initializes the number ranges, deletes data from test payment and dunning runs, and deletes cross-company code transactions and customer credit control data...see full standard documentation available for this report. Also check out the submitted Comments related to this SAP report and the details below to see which OBJECTS it interacts with such as TABLES, FUNCTION MODULES, INCLUDES ETC.
If you would like to execute this report or see the full code listing simply enter SAPF020 into the relevant SAP transactions such as SE38 or SE80
This report can be called from another progam/report simply by using the ABAP SUBMIT statement, see below for example ABAP code snipts of how to do this.
Selection Text: X_TESTL = Test run
Selection Text: X_NOWAR = Suppress repetitive warnings
Selection Text: X_MACO = Delete own matchcodes
Selection Text: X_KREDIT = Regenerate credit limits
Selection Text: X_CODATA = Delete CO data
Selection Text: BUKRS = Company code
Title: Reset Transaction Data
Text Symbol: 205 = Caution: Payment runs with reference to productive company code found
Text Symbol: 206 = Caution: Following error occurred when deleting G/L data:
Text Symbol: 207 = No general ledger data was generated in this company code
Text Symbol: 301 = Customer credit limits updated
Text Symbol: 302 = Credit Exposure Transferred to Credit Management
Text Symbol: 400 = Program Started By:
Text Symbol: 401 = Start Date
Text Symbol: 402 = Start Time
Text Symbol: 403 = Stop Date
Text Symbol: 404 = Stop Time
Text Symbol: 405 = Table
Text Symbol: 406 = Short Description
Text Symbol: 407 = Records Read
Text Symbol: 408 = Records Deleted
Text Symbol: 409 = Problems
Text Symbol: 204 = Caution: Dunning runs with reference to productive company code found
Text Symbol: 010 = Company Code: $BUKRS
Text Symbol: 011 = Update Run
Text Symbol: 012 = Test Run
Text Symbol: 015 = Table
Text Symbol: 016 = Records Read
Text Symbol: 017 = Record(s) deleted
Text Symbol: 018 = Problems
Text Symbol: 019 = Records Initialized
Text Symbol: 020 = Short Description of Table
Text Symbol: 021 = FI Transaction Data (SAPF020)
Text Symbol: 050 = Document Segment
Text Symbol: 051 = Change Documents
Text Symbol: 052 = Dunning Data
Text Symbol: 053 = Held documents
Text Symbol: 100 = ****************************************************************
INCLUDE F020TOP.
INCLUDE RFDBRMAC.
No SAP DATABASE tables are accessed within this REPORT code!
BAL_LOG_CREATE CALL FUNCTION 'BAL_LOG_CREATE' EXPORTING i_s_log = gs_log IMPORTING e_log_handle = gs_log_handle EXCEPTIONS log_header_inconsistent = 1 OTHERS = 2.
FI_CM_GET_CONTROL_AREAS CALL FUNCTION 'FI_CM_GET_CONTROL_AREAS' "begin ALRK230440 EXPORTING i_bukrs = bukrs TABLES t_kkbtab = gt_t014.
RK_KOKRS_FIND CALL FUNCTION 'RK_KOKRS_FIND' EXPORTING bukrs = bukrs IMPORTING kokrs = kokrs.
RK_BUKRS_OF_KOKRS CALL FUNCTION 'RK_BUKRS_OF_KOKRS' EXPORTING kokrs = kokrs TABLES t_bukrs = t_bukrs.
RSLG_WRITE_SYSLOG_ENTRY CALL FUNCTION 'RSLG_WRITE_SYSLOG_ENTRY' EXPORTING data_area = add_ons sl_message_area = 'C0' sl_message_subid = '0'.
RK_DELETE_CO_DATAS_FROM_BUKRS CALL FUNCTION 'RK_DELETE_CO_DATAS_FROM_BUKRS' EXPORTING bukrs = bukrs t_delete = x_echtl TABLES ycobk = ycobk stk = icomm EXCEPTIONS not_all_delete = 1 end_of_read_or_delete = 2 error_message = 3.
K_RCL_DELETE_ICCF_POSTINGS * call function 'K_RCL_DELETE_ICCF_POSTINGS' "ALRK115089 * exporting "ALRK115089 * i_bukrs = bukrs "ALRK115089 * i_test = x_testl "ALRK115089 * exceptions "ALRK115089 * others = 99. "ALRK115089
KE_TRANSACTION_DATA_DELETE CALL FUNCTION 'KE_TRANSACTION_DATA_DELETE' EXPORTING rbukrs = bukrs test_indicator = x_testl log = space flag_glpca_commit = 'X' "<<< Insert - Note 363768 EXCEPTIONS OTHERS = 99.
K_RCL_DELETE_ICCF_POSTINGS CALL FUNCTION 'K_RCL_DELETE_ICCF_POSTINGS' EXPORTING i_bukrs = bukrs i_test = x_testl EXCEPTIONS OTHERS = 99.
CASH_FORECAST_DELETE_ALL_DATA CALL FUNCTION 'CASH_FORECAST_DELETE_ALL_DATA' EXPORTING i_bukrs = bukrs i_test_only = x_testl TABLES fd_stk = icomm EXCEPTIONS OTHERS = 1.
G_DELETE_TEST_DATA CALL FUNCTION 'G_DELETE_TEST_DATA' EXPORTING bukrs = bukrs liste = space test = x_test TABLES stat_tab = icomm EXCEPTIONS error_message = 01.
UKM_IS_ACTIVE CALL FUNCTION 'UKM_IS_ACTIVE' IMPORTING e_active = l_active.
G_READ_FIXED_LEDGERS CALL FUNCTION 'G_READ_FIXED_LEDGERS' EXPORTING table = 'GLT0' with_parallel_ledgers = 'X' TABLES ledgers = ledger.
G_READ_FIXED_LEDGERS CALL FUNCTION 'G_READ_FIXED_LEDGERS' EXPORTING table = 'GLT3' with_parallel_ledgers = 'X' TABLES ledgers = ledger.
CHECK_JURISDICTION_ACTIVE CALL FUNCTION 'CHECK_JURISDICTION_ACTIVE' EXPORTING i_bukrs = bukrs IMPORTING e_isactive = isactive e_external = external EXCEPTIONS OTHERS = 1.
CHECK_JURISDICTION_ACTIVE CALL FUNCTION 'CHECK_JURISDICTION_ACTIVE' EXPORTING i_bukrs = bukrs IMPORTING e_isactive = isactive e_external = external EXCEPTIONS OTHERS = 1.
DD_GET_NAMETAB CALL FUNCTION 'DD_GET_NAMETAB' EXPORTING status = 'A' tabname = 'BSEG' IMPORTING x030l_wa = i_x030l TABLES x031l_tab = dummy_x031l.
ACE_DATA_DELETE CALL FUNCTION 'ACE_DATA_DELETE' "#EC EXISTS EXPORTING * IT_COMP_RANGE = it_bukrs_range = lt_bukrs_range ib_send_warning_popup = space ib_check_authority = space ib_lock_ace = space ib_testrun = iv_testrun IMPORTING et_statistics = lt_statistics * ET_RETURN = .
FAGL_DEL_T811D_GLF_FOR_BUKRS CALL FUNCTION 'FAGL_DEL_T811D_GLF_FOR_BUKRS' EXPORTING id_bukrs = iv_bukrs id_testrun = iv_testrun IMPORTING ed_counter = itab-count1.
REUSE_ALV_LIST_DISPLAY CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY' EXPORTING i_callback_program = g_repid is_layout = ls_layout it_fieldcat = lt_fcat it_events = lt_eventtab TABLES t_outtab = gt_alv_output EXCEPTIONS program_error = 1 OTHERS = 2.
REUSE_ALV_FIELDCATALOG_MERGE CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE' EXPORTING i_structure_name = gc_struc_name CHANGING ct_fieldcat = xt_fcat EXCEPTIONS inconsistent_interface = 1 program_error = 2 OTHERS = 3.
REUSE_ALV_EVENTS_GET CALL FUNCTION 'REUSE_ALV_EVENTS_GET' EXPORTING i_list_type = 0 IMPORTING et_events = xt_eventtab EXCEPTIONS list_type_wrong = 1 OTHERS = 2.
REUSE_ALV_COMMENTARY_WRITE CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE' EXPORTING it_list_commentary = gt_top_of_page.
FI_MESSAGE_CHECK CALL FUNCTION 'FI_MESSAGE_CHECK' EXCEPTIONS no_message = 04.
FI_MESSAGE_SORT CALL FUNCTION 'FI_MESSAGE_SORT'.
FI_MESSAGE_GET CALL FUNCTION 'FI_MESSAGE_GET' TABLES t_fimsg = lt_fimsg.
BAL_LOG_MSG_ADD CALL FUNCTION 'BAL_LOG_MSG_ADD' EXPORTING i_log_handle = gs_log_handle i_s_msg = ls_message.
BAL_DSP_PROFILE_SINGLE_LOG_GET * CALL FUNCTION 'BAL_DSP_PROFILE_SINGLE_LOG_GET' * IMPORTING * E_S_DISPLAY_PROFILE = ls_profile * EXCEPTIONS * OTHERS = 1.
BAL_DSP_PROFILE_NO_TREE_GET CALL FUNCTION 'BAL_DSP_PROFILE_NO_TREE_GET' IMPORTING e_s_display_profile = ls_profile.
BAL_DSP_LOG_DISPLAY CALL FUNCTION 'BAL_DSP_LOG_DISPLAY' EXPORTING i_s_display_profile = ls_profile i_t_log_handle = gt_log_handle.
BAL_DSP_LOG_PRINT CALL FUNCTION 'BAL_DSP_LOG_PRINT' EXPORTING i_s_list_append = 'X'"gc_x "'X' i_s_display_profile = ls_profile i_t_log_handle = gt_log_handle.
BAL_LOG_MSG_ADD_FREE_TEXT CALL FUNCTION 'BAL_LOG_MSG_ADD_FREE_TEXT' EXPORTING i_log_handle = gs_log_handle i_msgty = mess_msgty i_probclass = gc_4 i_text = iv_freetext EXCEPTIONS log_not_found = 1 msg_inconsistent = 2 log_is_full = 3 OTHERS = 4.
BAL_LOG_MSG_ADD CALL FUNCTION 'BAL_LOG_MSG_ADD' EXPORTING i_log_handle = gs_log_handle i_s_msg = ls_msg.
CALL FUNCTION 'ISJP_APPLICATION_CHECK' IMPORTING ev_activ = lv_isjp_active.
ISJP_DELETE_TEST_DATA CALL FUNCTION 'ISJP_DELETE_TEST_DATA' EXPORTING iv_bukrs = bukrs iv_simulate = x_simulate TABLES it_stati = it_icomm EXCEPTIONS error_del_isjp = 1 OTHERS = 2.
Although this basic information may have limited use it does provide an easy to find location to store any knowledge about this program/report.
The contribute/comments section below therefore offer's an opportunity for anyone to add additional information. This can be anything from useful hints, tips and screen shots to relevant SAP notes or anything else you feel is relevant to this report.
This will then be available for everyone to easily find by simply searching on the report name SAPF020 or its description.