SAP Reports / Programs

RSETESTD SAP ABAP Report - Delete IDocs







RSETESTD is a standard Executable ABAP Report available within your SAP system (depending on your version and release level). It is used for This report deletes IDocs without archiving them...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 RSETESTD into the relevant SAP transactions such as SE38 or SE80


Transaction Code(s):

Below is a list of transaction codes which are relevant to this SAP report

WE11 - Delete IDocs


ABAP code to call this SAP report using the submit statement

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.






SUBMIT RSETESTD. "Basic submit
SUBMIT RSETESTD AND RETURN. "Return to original report after report execution complete
SUBMIT RSETESTD VIA SELECTION-SCREEN. "Display selection screen of submitted report to user
    See more syntax options for the ABAP SUBMIT statement


Text pool values


Selection Text: GP_INTRF = Delete Workflow Data
Selection Text: GP_LOGDL = Delete Application Log
Selection Text: GP_MAXCT = Maximum Number of IDocs
Selection Text: GP_REL = Delete Links
Selection Text: GP_TEST = Test Run
Selection Text: GP_TRFC = Delete tRFC Entries
Selection Text: GS_CREDA = Created On
Selection Text: GS_CRETI = Created At
Selection Text: GS_DIREC = Direction
Selection Text: GS_DOCNU = IDoc Number
Selection Text: GS_STATU = Current Status
Selection Text: P_COM = Commit Counter
Selection Text: GS_CIMTY = D .
Selection Text: GS_IDOCT = D .
Selection Text: GS_MESCO = D .
Selection Text: GS_MESFC = D .
Selection Text: GS_MESTY = D .
Selection Text: GS_RCVPC = D .
Selection Text: GS_RCVPN = D .
Selection Text: GS_RCVPR = D .
Selection Text: GS_RCVPT = D .
Selection Text: GS_SNDPC = D .
Selection Text: GS_SNDPN = D .
Selection Text: GS_SNDPR = D .
Selection Text: GS_SNDPT = D .
Selection Text: TEST = D .
Title: Delete IDocs
Text Symbol: 001 = IDoc Selection
Text Symbol: 002 = Additional Functions
Text Symbol: 003 = Delete IDocs
Text Symbol: 004 = IDocs
Text Symbol: 005 = Links
Text Symbol: 006 = Workflows
Text Symbol: 007 = Application Logs
Text Symbol: 008 = CPI-C
Text Symbol: 009 = tRFC
Text Symbol: 011 = Test run performed
Text Symbol: 012 = Update run performed





Text Symbol: 013 = Message Type
Text Symbol: 014 = Status
Text Symbol: 015 = *
Text Symbol: 016 = Delete IDocs?
Text Symbol: 017 = In an update run, all selected IDocs will be deleted permanently.
Text Symbol: 018 = OK
Text Symbol: 019 = Test Run
Text Symbol: 020 = Delete IDocs
Text Symbol: 021 = Simulation: Deletion of IDocs (Test Run)
Text Symbol: 022 = Total
Text Symbol: 023 = IDoc(s)
Text Symbol: 024 = Deleted
Text Symbol: 025 = RFC Entries:
Text Symbol: 026 = Sender
Text Symbol: 027 = Recipients
001 | IDocs | Links | Workflows |Logs | CPI-C | tRFC |


INCLUDES used within this REPORT RSETESTD

INCLUDE LEDI1D01.


TABLES used within REPORT and the associated SELECT statement:

No SAP DATABASE tables are accessed within this REPORT code!


Function Modules used within report and the associated call statement:

POPUP_TO_CONFIRM CALL FUNCTION 'POPUP_TO_CONFIRM' EXPORTING titlebar = text-016 text_question = text-017 text_button_1 = text-018 icon_button_1 = ' ' text_button_2 = text-019 icon_button_2 = ' ' default_button = '2' display_cancel_button = ' ' IMPORTING answer = l_answer EXCEPTIONS OTHERS = 2.

EDI_DOCUMENT_DELETE CALL FUNCTION 'EDI_DOCUMENT_DELETE' EXPORTING document_number = -docnum EXCEPTIONS idoc_does_not_exist = 1 document_foreign_lock = 2 idoc_cannot_be_deleted = 3 not_all_tables_deleted = 4 OTHERS = 5.

DB_COMMIT CALL FUNCTION 'DB_COMMIT'.

DB_COMMIT CALL FUNCTION 'DB_COMMIT'.

SWD_WFD_TASKS_GET CALL FUNCTION 'SWD_WFD_TASKS_GET' EXPORTING task = wa_task-task get_detail = on TABLES task_list = gt_workflow_task.

OWN_LOGICAL_SYSTEM_GET CALL FUNCTION 'OWN_LOGICAL_SYSTEM_GET' IMPORTING OWN_LOGICAL_SYSTEM = OWN_LOGSYS.

EDI_DOCUMENT_OPEN_FOR_READ CALL FUNCTION 'EDI_DOCUMENT_OPEN_FOR_READ' EXPORTING document_number = gd_edidc-docnum db_read_option = no_db_read ** IMPORTING ** idoc_control = gd_idoc_control EXCEPTIONS document_foreign_lock = 1 document_not_exist = 2 document_number_invalid = 3 OTHERS = 4.

SWI_WORKITEMS_OF_OBJECT_GET CALL FUNCTION 'SWI_WORKITEMS_OF_OBJECT_GET' EXPORTING objtype = gd_objid-objtype objkey = gd_objid-objkey TABLES itemlist = gt_workitem.

SWW_WI_DELETE CALL FUNCTION 'SWW_WI_DELETE' EXPORTING wi_id = gd_workitem-wi_id do_commit = off ** CREATE_EVENT = off delete_log = on EXCEPTIONS update_failed = 1 OTHERS = 2.

SREL_GET_NEXT_RELATIONS CALL FUNCTION 'SREL_GET_NEXT_RELATIONS' EXPORTING object = gd_relation_object ** ROLETYPE = ' ' ** RELATIONTYPE = ' ' max_hops = 1 TABLES links = gt_relation EXCEPTIONS internal_error = 1 no_logsys = 2 OTHERS = 3.






BINARY_RELATION_DELETE CALL FUNCTION 'BINARY_RELATION_DELETE' EXPORTING obj_rolea = gd_relation_object_rolea obj_roleb = gd_relation_next relationtype = gd_relation-reltype fire_events = off EXCEPTIONS entry_not_existing = 1 internal_error = 2 no_relation = 3 no_role = 4 OTHERS = 5.

EDI_DOCUMENT_READ_ALL_STATUS CALL FUNCTION 'EDI_DOCUMENT_READ_ALL_STATUS' EXPORTING document_number = gd_edidc-docnum TABLES int_edids = gt_idoc_status EXCEPTIONS document_not_open = 1 no_status_record_found = 2 OTHERS = 3.

EDI_DOCUMENT_CLOSE_READ CALL FUNCTION 'EDI_DOCUMENT_CLOSE_READ' EXPORTING document_number = gd_edidc-docnum EXCEPTIONS document_not_open = 1 parameter_error = 2 OTHERS = 3.

EDI_DOCUMENT_DELETE CALL FUNCTION 'EDI_DOCUMENT_DELETE' EXPORTING document_number = gd_edidc-docnum EXCEPTIONS idoc_does_not_exist = 1 document_foreign_lock = 2 idoc_cannot_be_deleted = 3 not_all_tables_deleted = 4 OTHERS = 5.

BAL_DB_DELETE CALL FUNCTION 'BAL_DB_DELETE' EXPORTING ** I_T_LOGS_TO_DELETE = ** I_T_LOG_HANDLE = i_t_lognumber = gt_bal_logn ** I_CLIENT = SYST-MANDT i_in_update_task = off i_with_commit_work = off EXCEPTIONS no_logs_specified = 1 OTHERS = 2.

SAPGUI_PROGRESS_INDICATOR CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR' EXPORTING percentage = gd_percent text = progress_title.

BAL_DB_DELETE CALL FUNCTION 'BAL_DB_DELETE' EXPORTING ** I_T_LOGS_TO_DELETE = ** I_T_LOG_HANDLE = i_t_lognumber = gt_bal_logn ** I_CLIENT = SYST-MANDT i_in_update_task = off i_with_commit_work = off EXCEPTIONS no_logs_specified = 1 OTHERS = 2.

RSLG_WRITE_SYSLOG_ENTRY CALL FUNCTION 'RSLG_WRITE_SYSLOG_ENTRY' EXPORTING DATA_WORD1 = 'RSETESTD' DATA_WORD2 = gd_total DATA_WORD3 = text-023 DATA_WORD4 = text-024 SL_MESSAGE_AREA = 'C4' SL_MESSAGE_SUBID = '1' EXCEPTIONS OTHERS = 0.

REUSE_ALV_GRID_DISPLAY CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY' EXPORTING i_callback_program = sy-repid i_callback_pf_status_set = 'SET_PF_STATUS' i_callback_user_command = 'USER_COMMAND' i_callback_top_of_page = 'ADD_INFORMATION_HEADER' i_grid_title = text-003 it_fieldcat = it_fieldcatalog it_sort = it_sorttable is_layout = wa_layout TABLES t_outtab = it_structure EXCEPTIONS PROGRAM_ERROR = 1 OTHERS = 2 .

REUSE_ALV_COMMENTARY_WRITE CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE' EXPORTING it_list_commentary = it_comment.



Contribute (Add Comments)

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 RSETESTD or its description.