SAP Reports / Programs | Archiving | SAP Utilities | Archiving(IS-U-TO-ARC) SAP IS

REPDAR_ARCH_HEAD SAP ABAP Report - Archive print document headers







REPDAR_ARCH_HEAD is a standard Executable ABAP Report available within your SAP system (depending on your version and release level). It is used for Archive print document headers This report carries out the second step in archiving print document headers: Writing print document headers to an archive file, based on the analysis carried out in the first step...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 REPDAR_ARCH_HEAD into the relevant SAP transactions such as SE38 or SE80


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 REPDAR_ARCH_HEAD. "Basic submit
SUBMIT REPDAR_ARCH_HEAD AND RETURN. "Return to original report after report execution complete
SUBMIT REPDAR_ARCH_HEAD 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: SE_VKONT = D Contract account
Selection Text: SE_PORTI = D Portion
Selection Text: SE_OPBEL = D Number of print document
Selection Text: P_TESTL = Test run
Selection Text: P_LFZTIM = End time
Selection Text: P_LFZDAT = End date
Selection Text: P_LAUFZ = Runtime restriction active
Selection Text: P_DETAIL = Detailed log
Selection Text: P_COMM = Comment for archive run
Selection Text: P_ALLG = Short log only
Title: Archive print document headers
Text Symbol: S04 = Additional restriction of archiving quantity
Text Symbol: S03 = Log type
Text Symbol: S02 = Runtime Restriction
Text Symbol: S01 = Technical control
Text Symbol: P18 = Number of Related ERDTS Entries
Text Symbol: P17 = No. of Selected ERDTS Entries
Text Symbol: P16 = No. of Associated DBEOSB Entries
Text Symbol: P15 = No. of Selected DBEOSB Entries
Text Symbol: P14 = No. of Associated EITERDK Entries
Text Symbol: P13 = No. of Selected EITERDK Entries
Text Symbol: P12 = Non-archived print document headers
Text Symbol: P11 = No. of Related DBERDR entries
Text Symbol: P10 = No. of Related DBERDU Entries
Text Symbol: P09 = No. of related ERDB entries
Text Symbol: P08 = Number of Related ERDO Entries
Text Symbol: P07 = Archived print document headers
Text Symbol: P06 = Display of selected DBERDR entries
Text Symbol: P05 = Display of selected DBERDU entries
Text Symbol: P04 = Display of selected ERDB entries
Text Symbol: P03 = Display of selected ERDO entries
Text Symbol: P02 = Archivable print document headers
Text Symbol: P01 = Statistics
Text Symbol: A00 = >>> Test Run <<<
Text Symbol: 007 = Number Accp. ETAXERDK Entries
Text Symbol: 006 = Number of Accp.ECHANGE_SERV.Entries
Text Symbol: 005 = Number of Sel. ECHANGE_SERV.Entries
Text Symbol: 001 = Number of Selected ETAXERDK Entries





INCLUDES used within this REPORT REPDAR_ARCH_HEAD

INCLUDE: REPDAR01_TYP,
REPDAR01_CON,
REPDAR01_TOP.


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:

ARCHIVE_OPEN_FOR_WRITE CALL FUNCTION 'ARCHIVE_OPEN_FOR_WRITE' EXPORTING call_delete_job_in_test_mode = xv_testl create_archive_file = lv_crt_arc object = co_arc_objh comments = xv_comment output_sel_screen_when_dialog = co_true output_sel_screen_when_batch = co_true IMPORTING archive_handle = wa_arc_data-handle EXCEPTIONS internal_error = 1 object_not_found = 2 open_error = 3 not_authorized = 4 OTHERS = 5.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '201'.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '430'.

PROGRESS_INDICATOR CALL FUNCTION 'PROGRESS_INDICATOR' EXPORTING i_msgid = 'EARC' i_msgno = '426' i_msgv1 = wa_statistic-erdk-process i_processed = wa_statistic-erdk-process i_output_immediately = co_true.

ARCHIVE_NEW_OBJECT CALL FUNCTION 'ARCHIVE_NEW_OBJECT' EXPORTING archive_handle = wa_arc_data-handle object_id = lv_archive_objid EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_object = -erdk-opbel i_msgtype = '2' i_msgid = 'EARC' i_msgno = '411' i_msgv1 = sy-subrc i_msgv2 = -erdk-opbel.

ARCHIVE_PUT_RECORD CALL FUNCTION 'ARCHIVE_PUT_RECORD' EXPORTING archive_handle = wa_arc_data-handle record = -erdk record_structure = 'ERDK' EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_PUT_RECORD CALL FUNCTION 'ARCHIVE_PUT_RECORD' EXPORTING archive_handle = wa_arc_data-handle record = -eiterdk record_structure = 'EITERDK' EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_PUT_RECORD CALL FUNCTION 'ARCHIVE_PUT_RECORD' EXPORTING archive_handle = wa_arc_data-handle record = -etax record_structure = 'ETAXERDK' EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_PUT_TABLE CALL FUNCTION 'ARCHIVE_PUT_TABLE' EXPORTING archive_handle = wa_arc_data-handle record_structure = 'ERDO' TABLES table = -erdo EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_PUT_TABLE CALL FUNCTION 'ARCHIVE_PUT_TABLE' EXPORTING archive_handle = wa_arc_data-handle record_structure = 'DBERDU' TABLES table = -erdu EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_PUT_TABLE CALL FUNCTION 'ARCHIVE_PUT_TABLE' EXPORTING archive_handle = wa_arc_data-handle record_structure = 'DBERDR' TABLES table = -erdr EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_PUT_TABLE CALL FUNCTION 'ARCHIVE_PUT_TABLE' EXPORTING archive_handle = wa_arc_data-handle record_structure = 'ERDB' TABLES table = -erdb EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_PUT_TABLE CALL FUNCTION 'ARCHIVE_PUT_TABLE' EXPORTING archive_handle = wa_arc_data-handle record_structure = 'ERDTS' TABLES table = -erdts EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_PUT_TABLE CALL FUNCTION 'ARCHIVE_PUT_TABLE' EXPORTING archive_handle = wa_arc_data-handle record_structure = 'DBEOSB' TABLES table = -eosb EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_PUT_TABLE CALL FUNCTION 'ARCHIVE_PUT_TABLE' EXPORTING archive_handle = wa_arc_data-handle record_structure = 'ECHANGE_SERVICE' TABLES table = -chgserv EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 invalid_record_structure = 3 OTHERS = 4.

ARCHIVE_SAVE_OBJECT CALL FUNCTION 'ARCHIVE_SAVE_OBJECT' EXPORTING archive_handle = wa_arc_data-handle EXCEPTIONS file_io_error = 1 internal_error = 2 open_error = 3 termination_requested = 4 wrong_access_to_archive = 5 OTHERS = 6.






ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_object = -erdk-opbel i_msgtype = '2' i_msgid = 'EARC' i_msgno = '412' i_msgv1 = sy-subrc i_msgv2 = -erdk-opbel.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_object = -erdk-opbel i_msgtype = '1' i_msgid = 'EARC' i_msgno = '428' i_msgv1 = -erdk-opbel.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_object = -erdk-opbel i_msgtype = '2' i_msgid = 'EARC' i_msgno = '429' i_msgv1 = sy-subrc i_msgv2 = -erdk-opbel.

ISU_DB_ERDO_SELECT CALL FUNCTION 'ISU_DB_ERDO_SELECT' TABLES xt_opbel = yt_opbel yt_erdo = lt_erdo EXCEPTIONS input_error = 1 not_found = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '427' i_msgv1 = sy-subrc i_msgv2 = 'DBERDO'.

ISU_DB_DBERDR_SELECT CALL FUNCTION 'ISU_DB_DBERDR_SELECT' TABLES xt_opbel = yt_opbel yt_dberdr = lt_erdr EXCEPTIONS input_error = 1 not_found = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '427' i_msgv1 = sy-subrc i_msgv2 = 'DBERDR'.

ISU_DB_DBERDU_SELECT CALL FUNCTION 'ISU_DB_DBERDU_SELECT' TABLES xt_opbel = yt_opbel yt_dberdu = lt_erdu EXCEPTIONS input_error = 1 not_found = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '427' i_msgv1 = sy-subrc i_msgv2 = 'DBERDU'.

ISU_DB_ERDB_SELECT CALL FUNCTION 'ISU_DB_ERDB_SELECT' TABLES xt_opbel = yt_opbel yt_erdb = lt_erdb EXCEPTIONS input_error = 1 not_found = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '427' i_msgv1 = sy-subrc i_msgv2 = 'ERDB'.

ISU_DB_EITERDK_SELECT_ARC CALL FUNCTION 'ISU_DB_EITERDK_SELECT_ARC' TABLES xt_opbel = yt_opbel yt_eiterdk = lt_eiterdk EXCEPTIONS input_error = 1 not_found = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '427' i_msgv1 = sy-subrc i_msgv2 = 'EITERDK'.

ISU_DB_DBEOSB_SELECT CALL FUNCTION 'ISU_DB_DBEOSB_SELECT' TABLES xt_opbel = yt_opbel yt_eosb = lt_dbeosb EXCEPTIONS input_error = 1 not_found = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '427' i_msgv1 = sy-subrc i_msgv2 = 'DBEOSB'.

ISU_DB_ERDTS_SELECT CALL FUNCTION 'ISU_DB_ERDTS_SELECT' TABLES xt_opbel = yt_opbel yt_erdts = lt_erdts EXCEPTIONS input_error = 1 not_found = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '427' i_msgv1 = sy-subrc i_msgv2 = 'ERDTS'.

ISU_DB_ETAXERDK_SELECT CALL FUNCTION 'ISU_DB_ETAXERDK_SELECT' TABLES xt_opbel = yt_opbel yt_etaxerdk = lt_etax EXCEPTIONS input_error = 1 not_found = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '427' i_msgv1 = sy-subrc i_msgv2 = 'ETAXERDK'.

ISU_DB_ECHANGE_SERVICE_SELECT



CALL FUNCTION 'ISU_DB_ECHANGE_SERVICE_SELECT' TABLES xt_opbel = yt_opbel yt_echange_service = lt_chgserv EXCEPTIONS input_error = 1 not_found = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '427' i_msgv1 = sy-subrc i_msgv2 = 'ECHANGE_SERVICE'.

ARCHIVE_WRITE_STATISTICS CALL FUNCTION 'ARCHIVE_WRITE_STATISTICS' EXPORTING archive_handle = wa_arc_data-handle.

ARCHIVE_CLOSE_FILE CALL FUNCTION 'ARCHIVE_CLOSE_FILE' EXPORTING archive_handle = wa_arc_data-handle EXCEPTIONS internal_error = 1 wrong_access_to_archive = 2 OTHERS = 3.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '2' i_msgid = 'EARC' i_msgno = '202'.

ISU_DB_ERDK_UPD_ARCFLAG CALL FUNCTION 'ISU_DB_ERDK_UPD_ARCFLAG' EXPORTING x_archive_flag = co_arcstat_5 TABLES xt_opbel = xt_opbel EXCEPTIONS update_error = 1 value_not_allowed = 2 general_fault = 3 OTHERS = 4.

DB_COMMIT CALL FUNCTION 'DB_COMMIT'.

ARCHIVE_PROTOCOL_COLLECT CALL FUNCTION 'ARCHIVE_PROTOCOL_COLLECT' EXPORTING i_msgtype = '1' i_msgid = 'EARC' i_msgno = '406' i_msgv1 = 'ERDK' i_msgv2 = lv_first_opbel i_msgv3 = lv_last_opbel i_msgv4 = sy-subrc.

ARCHIVE_PROTOCOL_INIT CALL FUNCTION 'ARCHIVE_PROTOCOL_INIT' EXPORTING i_detailprotocol = xv_detail.

ARCHIVE_PROTOCOL_WRITE CALL FUNCTION 'ARCHIVE_PROTOCOL_WRITE'.



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