SAP FUD_REVERSE_FI_DOCUMENT Function Module for UI Decoupling: Reverse FI document
FUD_REVERSE_FI_DOCUMENT is a standard fud reverse fi document SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for UI Decoupling: Reverse FI document processing and below is the pattern details for this FM, 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 fud reverse fi document FM, simply by entering the name FUD_REVERSE_FI_DOCUMENT into the relevant SAP transaction such as SE37 or SE38.
Function Group: FIN_UI_DECO_RC
Program Name: SAPLFIN_UI_DECO_RC
Main Program: SAPLFIN_UI_DECO_RC
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:

Function FUD_REVERSE_FI_DOCUMENT 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 'FUD_REVERSE_FI_DOCUMENT'"UI Decoupling: Reverse FI document.
EXPORTING
IV_BUKRS = "Company Code
* IV_STGRD = "Reason for Reversal
* IV_VOIDR = "Check void reason code
* IV_UPDATE = 'S' "Data element for domain BOOLE: TRUE (='X') and FALSE (=' ')
* IV_MODE = 'N' "Data element for domain BOOLE: TRUE (='X') and FALSE (=' ')
* IV_NO_AUTH = ' ' "Data element for domain BOOLE: TRUE (='X') and FALSE (=' ')
* IV_XSIMU = "Data element for domain BOOLE: TRUE (='X') and FALSE (=' ')
IV_BELNR = "Accounting Document Number
IV_GJAHR = "Fiscal Year
* IV_VERIFDOC_BUKRS = "Verif. Doc.: Company Code
* IV_VERIFDOC_VERIDOC_NO = "Verif. Doc.: Document Number
* IV_VERIFDOC_GJAHR = "Verif. Doc.: Fiscal Year
* IV_BVORG = ' ' "Number of Cross-Company Code Posting Transaction
* IV_STODT = '00000000' "Planned Date for the Reverse Posting
* IV_STOMO = "Fiscal Period
TABLES
ET_BAPIRET2 = "Return parameter table
* ET_REVERSAL_HEADER = "Standard Table Type for BKPF
* ET_REVERSAL_ITEMS = "Table Type for BSEG
IMPORTING Parameters details for FUD_REVERSE_FI_DOCUMENT
IV_BUKRS - Company Code
Data type: BUKRSOptional: No
Call by Reference: No ( called with pass by value option)
IV_STGRD - Reason for Reversal
Data type: STGRDOptional: Yes
Call by Reference: No ( called with pass by value option)
IV_VOIDR - Check void reason code
Data type: VOIDROptional: Yes
Call by Reference: No ( called with pass by value option)
IV_UPDATE - Data element for domain BOOLE: TRUE (='X') and FALSE (=' ')
Data type: BOOLE_DDefault: 'S'
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_MODE - Data element for domain BOOLE: TRUE (='X') and FALSE (=' ')
Data type: BOOLE_DDefault: 'N'
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_NO_AUTH - Data element for domain BOOLE: TRUE (='X') and FALSE (=' ')
Data type: BOOLE_DDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_XSIMU - Data element for domain BOOLE: TRUE (='X') and FALSE (=' ')
Data type: BOOLE_DOptional: Yes
Call by Reference: No ( called with pass by value option)
IV_BELNR - Accounting Document Number
Data type: BELNR_DOptional: No
Call by Reference: No ( called with pass by value option)
IV_GJAHR - Fiscal Year
Data type: GJAHROptional: No
Call by Reference: No ( called with pass by value option)
IV_VERIFDOC_BUKRS - Verif. Doc.: Company Code
Data type: BUKRSOptional: Yes
Call by Reference: No ( called with pass by value option)
IV_VERIFDOC_VERIDOC_NO - Verif. Doc.: Document Number
Data type: BELNR_DOptional: Yes
Call by Reference: No ( called with pass by value option)
IV_VERIFDOC_GJAHR - Verif. Doc.: Fiscal Year
Data type: GJAHROptional: Yes
Call by Reference: No ( called with pass by value option)
IV_BVORG - Number of Cross-Company Code Posting Transaction
Data type: BVORGDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_STODT - Planned Date for the Reverse Posting
Data type: STODTDefault: '00000000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_STOMO - Fiscal Period
Data type: MONATOptional: Yes
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for FUD_REVERSE_FI_DOCUMENT
ET_BAPIRET2 - Return parameter table
Data type: BAPIRET2_TOptional: No
Call by Reference: Yes
ET_REVERSAL_HEADER - Standard Table Type for BKPF
Data type: BKPF_TOptional: Yes
Call by Reference: Yes
ET_REVERSAL_ITEMS - Table Type for BSEG
Data type: BSEG_TOptional: Yes
Call by Reference: Yes
Copy and paste ABAP code example for FUD_REVERSE_FI_DOCUMENT 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_iv_bukrs | TYPE BUKRS, " | |||
| lt_et_bapiret2 | TYPE STANDARD TABLE OF BAPIRET2_T, " | |||
| lv_iv_stgrd | TYPE STGRD, " | |||
| lv_iv_voidr | TYPE VOIDR, " | |||
| lv_iv_update | TYPE BOOLE_D, " 'S' | |||
| lv_iv_mode | TYPE BOOLE_D, " 'N' | |||
| lv_iv_no_auth | TYPE BOOLE_D, " SPACE | |||
| lv_iv_xsimu | TYPE BOOLE_D, " | |||
| lv_iv_belnr | TYPE BELNR_D, " | |||
| lt_et_reversal_header | TYPE STANDARD TABLE OF BKPF_T, " | |||
| lv_iv_gjahr | TYPE GJAHR, " | |||
| lt_et_reversal_items | TYPE STANDARD TABLE OF BSEG_T, " | |||
| lv_iv_verifdoc_bukrs | TYPE BUKRS, " | |||
| lv_iv_verifdoc_veridoc_no | TYPE BELNR_D, " | |||
| lv_iv_verifdoc_gjahr | TYPE GJAHR, " | |||
| lv_iv_bvorg | TYPE BVORG, " SPACE | |||
| lv_iv_stodt | TYPE STODT, " '00000000' | |||
| lv_iv_stomo | TYPE MONAT. " |
|   CALL FUNCTION 'FUD_REVERSE_FI_DOCUMENT' "UI Decoupling: Reverse FI document |
| EXPORTING | ||
| IV_BUKRS | = lv_iv_bukrs | |
| IV_STGRD | = lv_iv_stgrd | |
| IV_VOIDR | = lv_iv_voidr | |
| IV_UPDATE | = lv_iv_update | |
| IV_MODE | = lv_iv_mode | |
| IV_NO_AUTH | = lv_iv_no_auth | |
| IV_XSIMU | = lv_iv_xsimu | |
| IV_BELNR | = lv_iv_belnr | |
| IV_GJAHR | = lv_iv_gjahr | |
| IV_VERIFDOC_BUKRS | = lv_iv_verifdoc_bukrs | |
| IV_VERIFDOC_VERIDOC_NO | = lv_iv_verifdoc_veridoc_no | |
| IV_VERIFDOC_GJAHR | = lv_iv_verifdoc_gjahr | |
| IV_BVORG | = lv_iv_bvorg | |
| IV_STODT | = lv_iv_stodt | |
| IV_STOMO | = lv_iv_stomo | |
| TABLES | ||
| ET_BAPIRET2 | = lt_et_bapiret2 | |
| ET_REVERSAL_HEADER | = lt_et_reversal_header | |
| ET_REVERSAL_ITEMS | = lt_et_reversal_items | |
| . " FUD_REVERSE_FI_DOCUMENT | ||
ABAP code using 7.40 inline data declarations to call FM FUD_REVERSE_FI_DOCUMENT
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.| DATA(ld_iv_update) | = 'S'. | |||
| DATA(ld_iv_mode) | = 'N'. | |||
| DATA(ld_iv_no_auth) | = ' '. | |||
| DATA(ld_iv_bvorg) | = ' '. | |||
| DATA(ld_iv_stodt) | = '00000000'. | |||
Search for further information about these or an SAP related objects