SAP TB_MASTER_AGREEMENT_CHECK_DEAL Function Module for Check Transaction Against Master Agreement









TB_MASTER_AGREEMENT_CHECK_DEAL is a standard tb master agreement check deal 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 Transaction Against Master Agreement 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 master agreement check deal FM, simply by entering the name TB_MASTER_AGREEMENT_CHECK_DEAL into the relevant SAP transaction such as SE37 or SE38.

Function Group: TBM3
Program Name: SAPLTBM3
Main Program: SAPLTBM3
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function TB_MASTER_AGREEMENT_CHECK_DEAL 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_MASTER_AGREEMENT_CHECK_DEAL'"Check Transaction Against Master Agreement
EXPORTING
RMAID = "Master Agreement
* DZTERM = "Zahlungstermin (für Betrag; falls leer: LfzBeg.)
* BUKRS = "Legal Entity (Buchungskreis)
* PARTNR = "Business Partner
* SGSART = "Product Type
* SFHAART = "Transaction Type
* WAERS = "Currency
* DBLFZ = "Start of Term
* DELFZ = "End of Term
* BNWHR = "Amount

EXCEPTIONS
MASTER_AGREEMENT = 1 ENTITY = 2 PARTNER = 3 DEALTYPE = 4 CURRENCY = 5 TERM = 6 AMOUNT = 7
.



IMPORTING Parameters details for TB_MASTER_AGREEMENT_CHECK_DEAL

RMAID - Master Agreement

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

DZTERM - Zahlungstermin (für Betrag; falls leer: LfzBeg.)

Data type: VTBFHAPO-DZTERM
Optional: Yes
Call by Reference: No ( called with pass by value option)

BUKRS - Legal Entity (Buchungskreis)

Data type: VTBMALE-BUKRS
Optional: Yes
Call by Reference: No ( called with pass by value option)

PARTNR - Business Partner

Data type: VTBMAPA-PARTNR
Optional: Yes
Call by Reference: No ( called with pass by value option)

SGSART - Product Type

Data type: VTBMADT-SGSART
Optional: Yes
Call by Reference: No ( called with pass by value option)

SFHAART - Transaction Type

Data type: VTBMADT-SFHAART
Optional: Yes
Call by Reference: No ( called with pass by value option)

WAERS - Currency

Data type: VTBMACR-WAERS
Optional: Yes
Call by Reference: No ( called with pass by value option)

DBLFZ - Start of Term

Data type: VTBFHAZU-DBLFZ
Optional: Yes
Call by Reference: No ( called with pass by value option)

DELFZ - End of Term

Data type: VTBFHAZU-DELFZ
Optional: Yes
Call by Reference: No ( called with pass by value option)

BNWHR - Amount

Data type: VTBFHAPO-BNWHR
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXCEPTIONS details

MASTER_AGREEMENT - Rahmenvertrag ist nicht vorgesehen oder zulässig

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

ENTITY - Buchungskreis ist nicht zulässig

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

PARTNER - Geschäftspartner ist nicht zulässig

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

DEALTYPE - Geschäftsart ist nicht zulässig

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

CURRENCY - Währung ist nicht zulässig

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

TERM - Laufzeit ist nicht zulässig

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

AMOUNT - Betrag ist nicht zulässig

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

Copy and paste ABAP code example for TB_MASTER_AGREEMENT_CHECK_DEAL 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_rmaid  TYPE VTBMA-RMAID, "   
lv_master_agreement  TYPE VTBMA, "   
lv_dzterm  TYPE VTBFHAPO-DZTERM, "   
lv_bukrs  TYPE VTBMALE-BUKRS, "   
lv_entity  TYPE VTBMALE, "   
lv_partnr  TYPE VTBMAPA-PARTNR, "   
lv_partner  TYPE VTBMAPA, "   
lv_sgsart  TYPE VTBMADT-SGSART, "   
lv_dealtype  TYPE VTBMADT, "   
lv_sfhaart  TYPE VTBMADT-SFHAART, "   
lv_currency  TYPE VTBMADT, "   
lv_term  TYPE VTBMADT, "   
lv_waers  TYPE VTBMACR-WAERS, "   
lv_dblfz  TYPE VTBFHAZU-DBLFZ, "   
lv_amount  TYPE VTBFHAZU, "   
lv_delfz  TYPE VTBFHAZU-DELFZ, "   
lv_bnwhr  TYPE VTBFHAPO-BNWHR. "   

  CALL FUNCTION 'TB_MASTER_AGREEMENT_CHECK_DEAL'  "Check Transaction Against Master Agreement
    EXPORTING
         RMAID = lv_rmaid
         DZTERM = lv_dzterm
         BUKRS = lv_bukrs
         PARTNR = lv_partnr
         SGSART = lv_sgsart
         SFHAART = lv_sfhaart
         WAERS = lv_waers
         DBLFZ = lv_dblfz
         DELFZ = lv_delfz
         BNWHR = lv_bnwhr
    EXCEPTIONS
        MASTER_AGREEMENT = 1
        ENTITY = 2
        PARTNER = 3
        DEALTYPE = 4
        CURRENCY = 5
        TERM = 6
        AMOUNT = 7
. " TB_MASTER_AGREEMENT_CHECK_DEAL




ABAP code using 7.40 inline data declarations to call FM TB_MASTER_AGREEMENT_CHECK_DEAL

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 RMAID FROM VTBMA INTO @DATA(ld_rmaid).
 
 
"SELECT single DZTERM FROM VTBFHAPO INTO @DATA(ld_dzterm).
 
"SELECT single BUKRS FROM VTBMALE INTO @DATA(ld_bukrs).
 
 
"SELECT single PARTNR FROM VTBMAPA INTO @DATA(ld_partnr).
 
 
"SELECT single SGSART FROM VTBMADT INTO @DATA(ld_sgsart).
 
 
"SELECT single SFHAART FROM VTBMADT INTO @DATA(ld_sfhaart).
 
 
 
"SELECT single WAERS FROM VTBMACR INTO @DATA(ld_waers).
 
"SELECT single DBLFZ FROM VTBFHAZU INTO @DATA(ld_dblfz).
 
 
"SELECT single DELFZ FROM VTBFHAZU INTO @DATA(ld_delfz).
 
"SELECT single BNWHR FROM VTBFHAPO INTO @DATA(ld_bnwhr).
 


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!