SAP CHANGEDOCUMENT_DELETE_V2 Function Module for









CHANGEDOCUMENT_DELETE_V2 is a standard changedocument delete v2 SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.


See here to view full function module documentation and code listing for changedocument delete v2 FM, simply by entering the name CHANGEDOCUMENT_DELETE_V2 into the relevant SAP transaction such as SE37 or SE38.

Function Group: SCD4
Program Name: SAPLSCD4
Main Program: SAPLSCD4
Appliation area: *
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update: 2



Function CHANGEDOCUMENT_DELETE_V2 pattern details

In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.
CALL FUNCTION 'CHANGEDOCUMENT_DELETE_V2'"
EXPORTING
* CLIENT = SY-MANDT "
OBJECTCLASS = "
* OBJECTID = ' ' "
* UP_TO_DATE = SY-DATUM "
* DISABLE_AUTHORITY_CHECK = ' ' "
* CHANGENR = ' ' "

EXCEPTIONS
NO_AUTHORITY = 1
.



IMPORTING Parameters details for CHANGEDOCUMENT_DELETE_V2

CLIENT -

Data type: CDHDR-MANDANT
Default: SY-MANDT
Optional: Yes
Call by Reference: No ( called with pass by value option)

OBJECTCLASS -

Data type: CDHDR-OBJECTCLAS
Optional: No
Call by Reference: No ( called with pass by value option)

OBJECTID -

Data type: CDHDR-OBJECTID
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

UP_TO_DATE -

Data type: CDHDR-UDATE
Default: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)

DISABLE_AUTHORITY_CHECK -

Data type: CDFLAG
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

CHANGENR -

Data type: CDHDR-CHANGENR
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXCEPTIONS details

NO_AUTHORITY -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for CHANGEDOCUMENT_DELETE_V2 Function Module

The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the newer method of declaring data variables on the fly. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8), which i why i have stuck to the origianl for this example.

DATA:
lv_client  TYPE CDHDR-MANDANT, "   SY-MANDT
lv_no_authority  TYPE CDHDR, "   
lv_objectclass  TYPE CDHDR-OBJECTCLAS, "   
lv_objectid  TYPE CDHDR-OBJECTID, "   SPACE
lv_up_to_date  TYPE CDHDR-UDATE, "   SY-DATUM
lv_disable_authority_check  TYPE CDFLAG, "   SPACE
lv_changenr  TYPE CDHDR-CHANGENR. "   SPACE

  CALL FUNCTION 'CHANGEDOCUMENT_DELETE_V2'  "
    EXPORTING
         CLIENT = lv_client
         OBJECTCLASS = lv_objectclass
         OBJECTID = lv_objectid
         UP_TO_DATE = lv_up_to_date
         DISABLE_AUTHORITY_CHECK = lv_disable_authority_check
         CHANGENR = lv_changenr
    EXCEPTIONS
        NO_AUTHORITY = 1
. " CHANGEDOCUMENT_DELETE_V2




ABAP code using 7.40 inline data declarations to call FM CHANGEDOCUMENT_DELETE_V2

The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.

"SELECT single MANDANT FROM CDHDR INTO @DATA(ld_client).
DATA(ld_client) = SY-MANDT.
 
 
"SELECT single OBJECTCLAS FROM CDHDR INTO @DATA(ld_objectclass).
 
"SELECT single OBJECTID FROM CDHDR INTO @DATA(ld_objectid).
DATA(ld_objectid) = ' '.
 
"SELECT single UDATE FROM CDHDR INTO @DATA(ld_up_to_date).
DATA(ld_up_to_date) = SY-DATUM.
 
DATA(ld_disable_authority_check) = ' '.
 
"SELECT single CHANGENR FROM CDHDR INTO @DATA(ld_changenr).
DATA(ld_changenr) = ' '.
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!