SAP Reports / Programs

RHCHECKRELATIONS SAP ABAP Report - Delete relationships without existing objects







RHCHECKRELATIONS is a standard Executable ABAP Report available within your SAP system (depending on your version and release level). It is used for CHECKING THE CONSISTENCY OF RELATIONSHIPS This report removes all inconsistent relationship records from the database...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 RHCHECKRELATIONS 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 RHCHECKRELATIONS. "Basic submit
SUBMIT RHCHECKRELATIONS AND RETURN. "Return to original report after report execution complete
SUBMIT RHCHECKRELATIONS 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: USERNAME = User Name
Selection Text: PLANVAR = Plan Version
Selection Text: OBJTYPE = Object Type
Selection Text: OBJID = Object ID / Personnel No.
Selection Text: DIRDEL = Direct delete (X=yes)
Title: Delete relationships without existing objects
Text Symbol: 100 = ERROR
Text Symbol: 036 = Select the nodes
Text Symbol: 035 = Repair
Text Symbol: 034 = Incorrect Period
Text Symbol: 033 = Target Object
Text Symbol: 032 = Confirmation
Text Symbol: 031 = No inconsistent records available
Text Symbol: 030 = Inconsistent Recs
Text Symbol: 027 = LIST OF INCONSISTENT RECORDS
Text Symbol: 025 = Delete selected records?
Text Symbol: 024 = Plan version does not exist (use F4 help)
Text Symbol: 023 = Following records were deleted
Text Symbol: 021 = Are these relationships to be adjusted to the target object period?
Text Symbol: 020 = Are the selected relationships to be deleted?
Text Symbol: 019 = Should the selected relationships be repaired?
Text Symbol: 016 = Not possible to add to database
Text Symbol: 015 = Deletion from database not possible
Text Symbol: 014 = Obj.type not permitted
Text Symbol: 013 = (the relationships under the selected nodes are also adjusted)
Text Symbol: 012 = (the relationships under the selected nodes are also deleted)
Text Symbol: 011 = (the relationships under the selected nodes are also repaired)


INCLUDES used within this REPORT RHCHECKRELATIONS

No INCLUDES are used within this REPORT code!


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_STEP CALL FUNCTION 'POPUP_TO_CONFIRM_STEP' "#EC * EXPORTING textline1 = text1 textline2 = text2 titel = 'Bestaetigung'(032) "Confirmation cancel_display = ' ' IMPORTING answer = l_rc.

TR_GET_SAPR3_TYPE CALL FUNCTION 'TR_GET_SAPR3_TYPE' "#EC * TABLES tt_cvers = l_components EXCEPTIONS no_tsyst_entry = 1 OTHERS = 2.

TR_GET_SAPR3_TYPE CALL FUNCTION 'TR_GET_SAPR3_TYPE' TABLES tt_cvers = lt_cvers EXCEPTIONS no_tsyst_entry = 1 OTHERS = 2.

POPUP_TO_CONFIRM_DEL CALL FUNCTION 'POPUP_TO_CONFIRM_DEL' EXPORTING titel = text-032 begda = '01011900' endda = '12319999' stext_1 = del_text IMPORTING answer = go_on.

RH_TURN_RELATION CALL FUNCTION 'RH_TURN_RELATION' EXPORTING otype = object_type EXCEPTIONS relation_not_reversible = 1 OTHERS = 2.

RH_INVERT_RELA_INFTY CALL FUNCTION 'RH_INVERT_RELA_INFTY' EXPORTING p1001_imp = int_p1001 IMPORTING p1001_exp = inv_p1001 EXCEPTIONS relation_not_reversible = 1 OTHERS = 2.

RH_GET_EXTERNAL_OBJECT_INFO CALL FUNCTION 'RH_GET_EXTERNAL_OBJECT_INFO' EXPORTING otype = obj_type * IMPORTING * I77EO = EXCEPTIONS no_external_object = 1 OTHERS = 2 .

RH_EXIST_OBJECT * CALL FUNCTION 'RH_EXIST_OBJECT' * EXPORTING * plvar = p_plog_plvar * otype = p_plog_otype * objid = p_plog_objid ** REALO = ' ' ** IMPORTING ** EXTERNAL_OBJECT = " wenn ext. Obj. dann kein check

RH_READ_OBJECT CALL FUNCTION 'RH_READ_OBJECT' EXPORTING plvar = p_plog_plvar otype = p_plog_otype objid = p_plog_objid IMPORTING obeg = obj_begda oend = obj_endda EXCEPTIONS not_found = 1 OTHERS = 2.

RHEO_EXIST_EXTOBJ CALL FUNCTION 'RHEO_EXIST_EXTOBJ' EXPORTING otype = obj_type realo = p_realo begda = '19000101' endda = '99991231' IMPORTING subrc = out_subrc EXCEPTIONS illegal_otype = 1 method_not_supported = 2 OTHERS = 3.

LVC_FIELDCATALOG_MERGE CALL FUNCTION 'LVC_FIELDCATALOG_MERGE' EXPORTING i_structure_name = 'P1001' CHANGING ct_fieldcat = gt_fieldcatalog.

RH_INVERT_RELA_INFTY CALL FUNCTION 'RH_INVERT_RELA_INFTY' EXPORTING p1001_imp = int_p1001 IMPORTING p1001_exp = inv_p1001 EXCEPTIONS relation_not_reversible = 1 OTHERS = 2.

RH_READ_OBJECT CALL FUNCTION 'RH_READ_OBJECT' EXPORTING objid = int_p1001-objid plvar = int_p1001-plvar otype = int_p1001-sclas * realo = int_p1001-sobid IMPORTING obeg = ins_begda oend = ins_endda EXCEPTIONS not_found = 1 OTHERS = 2.

RH_INVERT_RELA_INFTY CALL FUNCTION 'RH_INVERT_RELA_INFTY' EXPORTING p1001_imp = ins_p1001 IMPORTING p1001_exp = ins_p1001 EXCEPTIONS relation_not_reversible = 1 OTHERS = 2.

RH_READ_OBJECT CALL FUNCTION 'RH_READ_OBJECT' EXPORTING plvar = int_p1001-plvar otype = int_p1001-sclas realo = int_p1001-sobid IMPORTING obeg = ins_begda oend = ins_endda EXCEPTIONS not_found = 1 OTHERS = 2.

RH_INVERT_RELA_INFTY CALL FUNCTION 'RH_INVERT_RELA_INFTY' EXPORTING p1001_imp = ins_p1001 IMPORTING p1001_exp = ins_p1001 EXCEPTIONS relation_not_reversible = 1 OTHERS = 2.

RH_INSERT_INFTY_DIRECT CALL FUNCTION 'RH_INSERT_INFTY_DIRECT' EXPORTING vtask = 'D' TABLES innnn = ins_p1001 EXCEPTIONS no_authorization = 1 error_during_insert = 2 repid_form_initial = 3 corr_exit = 4 begda_greater_endda = 5 OTHERS = 6.

RH_CLEAR_BUFFER CALL FUNCTION 'RH_CLEAR_BUFFER'.

RH_CLEAR_PLOG_TAB





CALL FUNCTION 'RH_CLEAR_PLOG_TAB'.

RHAP_SUPPR_INTE_SET CALL FUNCTION 'RHAP_SUPPR_INTE_SET' EXPORTING suppr_inte = 'X'.

RH_UPDATE_DATABASE CALL FUNCTION 'RH_UPDATE_DATABASE' EXPORTING vtask = 'D' EXCEPTIONS corr_exit = 1 OTHERS = 2.

RHAP_SUPPR_INTE_SET CALL FUNCTION 'RHAP_SUPPR_INTE_SET' EXPORTING suppr_inte = ' '.

RHAP_SUPPR_INTE_SET CALL FUNCTION 'RHAP_SUPPR_INTE_SET' "note921108 EXPORTING suppr_inte = 'X'.

RH_DELETE_INFTY_DIRECT CALL FUNCTION 'RH_DELETE_INFTY_DIRECT' EXPORTING vtask = 'D' order_flg = ' ' commit_flg = 'X' authy = ' ' "note377627 TABLES innnn = del_no_inte "note390337 EXCEPTIONS no_authorization = 1 error_during_delete = 2 corr_exit = 3 OTHERS = 4.

RH_DELETE_INFTY_DIRECT CALL FUNCTION 'RH_DELETE_INFTY_DIRECT' EXPORTING vtask = 'D' order_flg = ' ' commit_flg = 'X' authy = ' ' "note377627 TABLES innnn = del_with_inte "note390337 EXCEPTIONS no_authorization = 1 error_during_delete = 2 corr_exit = 3 OTHERS = 4.



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