SAP TB_COVR_FI_DOCUMENT_CHECK Function Module for Check if FI Document Is Assigned to a Hedge
TB_COVR_FI_DOCUMENT_CHECK is a standard tb covr fi document check SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Check if FI Document Is Assigned to a Hedge 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 tb covr fi document check FM, simply by entering the name TB_COVR_FI_DOCUMENT_CHECK into the relevant SAP transaction such as SE37 or SE38.
Function Group: TB7F
Program Name: SAPLTB7F
Main Program:
Appliation area: F
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function TB_COVR_FI_DOCUMENT_CHECK 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 'TB_COVR_FI_DOCUMENT_CHECK'"Check if FI Document Is Assigned to a Hedge.
EXPORTING
IMP_BELNR = "FI key: document no.
IMP_BUKRS = "FI key: Company code
* IMP_BUZEI = '000' "FI key: Document line
* IMP_GJAHR = '0000' "FI key: Fiscal year
IMPORTING
EXP_COVERED_AMOUNT = "(Overall) amount of hedge in FC
EXP_COVERED_RATE = "(Mixed) rate of hedge
EXP_COVERED_AMOUNT_SIGN = "Sign: + inflow, - outflow
EXP_COVERED_LOC_AMOUNT = "(Overall) amount of hedge in LC
EXP_COVERED_LOC_SIGN = "Sign: + inflow, - outflow
TABLES
* EXP_VTBSIZU = "Table of allocated objects
* EXP_VTBSI = "Table of hedges
EXCEPTIONS
DOCUMENT_NOT_ALLOCATED = 1
IMPORTING Parameters details for TB_COVR_FI_DOCUMENT_CHECK
IMP_BELNR - FI key: document no.
Data type: BKPF-BELNROptional: No
Call by Reference: No ( called with pass by value option)
IMP_BUKRS - FI key: Company code
Data type: BKPF-BUKRSOptional: No
Call by Reference: No ( called with pass by value option)
IMP_BUZEI - FI key: Document line
Data type: BSEG-BUZEIDefault: '000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
IMP_GJAHR - FI key: Fiscal year
Data type: BKPF-GJAHRDefault: '0000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for TB_COVR_FI_DOCUMENT_CHECK
EXP_COVERED_AMOUNT - (Overall) amount of hedge in FC
Data type: BSEG-GBETROptional: No
Call by Reference: No ( called with pass by value option)
EXP_COVERED_RATE - (Mixed) rate of hedge
Data type: BSEG-KURSROptional: No
Call by Reference: No ( called with pass by value option)
EXP_COVERED_AMOUNT_SIGN - Sign: + inflow, - outflow
Data type: VTBSIZU-SSIGNTOptional: No
Call by Reference: No ( called with pass by value option)
EXP_COVERED_LOC_AMOUNT - (Overall) amount of hedge in LC
Data type: VTBSIZU-BZUOBOptional: No
Call by Reference: No ( called with pass by value option)
EXP_COVERED_LOC_SIGN - Sign: + inflow, - outflow
Data type: VTBSIZU-SSIGNBOptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for TB_COVR_FI_DOCUMENT_CHECK
EXP_VTBSIZU - Table of allocated objects
Data type: VTBSIZUOptional: Yes
Call by Reference: No ( called with pass by value option)
EXP_VTBSI - Table of hedges
Data type: VTBSIOptional: Yes
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
DOCUMENT_NOT_ALLOCATED - Document not allocated
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for TB_COVR_FI_DOCUMENT_CHECK 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_imp_belnr | TYPE BKPF-BELNR, " | |||
| lt_exp_vtbsizu | TYPE STANDARD TABLE OF VTBSIZU, " | |||
| lv_exp_covered_amount | TYPE BSEG-GBETR, " | |||
| lv_document_not_allocated | TYPE BSEG, " | |||
| lt_exp_vtbsi | TYPE STANDARD TABLE OF VTBSI, " | |||
| lv_imp_bukrs | TYPE BKPF-BUKRS, " | |||
| lv_exp_covered_rate | TYPE BSEG-KURSR, " | |||
| lv_imp_buzei | TYPE BSEG-BUZEI, " '000' | |||
| lv_exp_covered_amount_sign | TYPE VTBSIZU-SSIGNT, " | |||
| lv_imp_gjahr | TYPE BKPF-GJAHR, " '0000' | |||
| lv_exp_covered_loc_amount | TYPE VTBSIZU-BZUOB, " | |||
| lv_exp_covered_loc_sign | TYPE VTBSIZU-SSIGNB. " |
|   CALL FUNCTION 'TB_COVR_FI_DOCUMENT_CHECK' "Check if FI Document Is Assigned to a Hedge |
| EXPORTING | ||
| IMP_BELNR | = lv_imp_belnr | |
| IMP_BUKRS | = lv_imp_bukrs | |
| IMP_BUZEI | = lv_imp_buzei | |
| IMP_GJAHR | = lv_imp_gjahr | |
| IMPORTING | ||
| EXP_COVERED_AMOUNT | = lv_exp_covered_amount | |
| EXP_COVERED_RATE | = lv_exp_covered_rate | |
| EXP_COVERED_AMOUNT_SIGN | = lv_exp_covered_amount_sign | |
| EXP_COVERED_LOC_AMOUNT | = lv_exp_covered_loc_amount | |
| EXP_COVERED_LOC_SIGN | = lv_exp_covered_loc_sign | |
| TABLES | ||
| EXP_VTBSIZU | = lt_exp_vtbsizu | |
| EXP_VTBSI | = lt_exp_vtbsi | |
| EXCEPTIONS | ||
| DOCUMENT_NOT_ALLOCATED = 1 | ||
| . " TB_COVR_FI_DOCUMENT_CHECK | ||
ABAP code using 7.40 inline data declarations to call FM TB_COVR_FI_DOCUMENT_CHECK
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 BELNR FROM BKPF INTO @DATA(ld_imp_belnr). | ||||
| "SELECT single GBETR FROM BSEG INTO @DATA(ld_exp_covered_amount). | ||||
| "SELECT single BUKRS FROM BKPF INTO @DATA(ld_imp_bukrs). | ||||
| "SELECT single KURSR FROM BSEG INTO @DATA(ld_exp_covered_rate). | ||||
| "SELECT single BUZEI FROM BSEG INTO @DATA(ld_imp_buzei). | ||||
| DATA(ld_imp_buzei) | = '000'. | |||
| "SELECT single SSIGNT FROM VTBSIZU INTO @DATA(ld_exp_covered_amount_sign). | ||||
| "SELECT single GJAHR FROM BKPF INTO @DATA(ld_imp_gjahr). | ||||
| DATA(ld_imp_gjahr) | = '0000'. | |||
| "SELECT single BZUOB FROM VTBSIZU INTO @DATA(ld_exp_covered_loc_amount). | ||||
| "SELECT single SSIGNB FROM VTBSIZU INTO @DATA(ld_exp_covered_loc_sign). | ||||
Search for further information about these or an SAP related objects