SAP J_7L_CUST4_FORMEL Function Module for NOTRANSL: REA Formel für die Entgeltberechnung (Template)
J_7L_CUST4_FORMEL is a standard j 7l cust4 formel SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for NOTRANSL: REA Formel für die Entgeltberechnung (Template) 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 j 7l cust4 formel FM, simply by entering the name J_7L_CUST4_FORMEL into the relevant SAP transaction such as SE37 or SE38.
Function Group: J7LN
Program Name: SAPLJ7LN
Main Program: SAPLJ7LN
Appliation area: V
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function J_7L_CUST4_FORMEL 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 'J_7L_CUST4_FORMEL'"NOTRANSL: REA Formel für die Entgeltberechnung (Template).
EXPORTING
FORMEL = "
* DATUM = SY-DATUM "
* STFKZ = "
* FMENG = 1 "Component Quantity for Internal Calculation
* VRPNR = "
* VARIANTE = "
* MEINS = "
ENTNR = "
LAND1 = "
BUKRS = "
* PLVRS = "
* SOKOA = "
* STOFE = "
* STOFI = "
* VFLKL = "
CHANGING
ENTGE = "
TABLES
* POSITION = "
* FRAKTION = "
EXCEPTIONS
FORMEL_ERROR = 1
IMPORTING Parameters details for J_7L_CUST4_FORMEL
FORMEL -
Data type: J_7LE01-FORMELOptional: No
Call by Reference: Yes
DATUM -
Data type: SY-DATUMDefault: SY-DATUM
Optional: Yes
Call by Reference: Yes
STFKZ -
Data type: J_7LE15-STFKZOptional: Yes
Call by Reference: Yes
FMENG - Component Quantity for Internal Calculation
Data type: J_7LKB2-FMENGDefault: 1
Optional: Yes
Call by Reference: Yes
VRPNR -
Data type: J_7LV01-VRPNROptional: Yes
Call by Reference: Yes
VARIANTE -
Data type: J_7LVVARIANTEOptional: Yes
Call by Reference: Yes
MEINS -
Data type: MARA-MEINSOptional: Yes
Call by Reference: Yes
ENTNR -
Data type: J_7LE01-ENTNROptional: No
Call by Reference: Yes
LAND1 -
Data type: J_7LE01-LAND1Optional: No
Call by Reference: Yes
BUKRS -
Data type: J_7LP01-BUKRSOptional: No
Call by Reference: Yes
PLVRS -
Data type: J_7LP01-PLVRSOptional: Yes
Call by Reference: Yes
SOKOA -
Data type: J_7LP02-SOKOAOptional: Yes
Call by Reference: Yes
STOFE -
Data type: J_7LP02-STOFEOptional: Yes
Call by Reference: Yes
STOFI -
Data type: J_7LRSTOFIOptional: Yes
Call by Reference: Yes
VFLKL -
Data type: J_7LP02-VFLKLOptional: Yes
Call by Reference: Yes
CHANGING Parameters details for J_7L_CUST4_FORMEL
ENTGE -
Data type: J_7LV1P-NETWEOptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for J_7L_CUST4_FORMEL
POSITION -
Data type: J_7LV1POptional: Yes
Call by Reference: No ( called with pass by value option)
FRAKTION -
Data type: J_7LKB3Optional: Yes
Call by Reference: Yes
EXCEPTIONS details
FORMEL_ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for J_7L_CUST4_FORMEL 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_entge | TYPE J_7LV1P-NETWE, " | |||
| lv_formel | TYPE J_7LE01-FORMEL, " | |||
| lt_position | TYPE STANDARD TABLE OF J_7LV1P, " | |||
| lv_formel_error | TYPE J_7LV1P, " | |||
| lv_datum | TYPE SY-DATUM, " SY-DATUM | |||
| lv_stfkz | TYPE J_7LE15-STFKZ, " | |||
| lv_fmeng | TYPE J_7LKB2-FMENG, " 1 | |||
| lv_vrpnr | TYPE J_7LV01-VRPNR, " | |||
| lv_variante | TYPE J_7LVVARIANTE, " | |||
| lv_meins | TYPE MARA-MEINS, " | |||
| lv_entnr | TYPE J_7LE01-ENTNR, " | |||
| lt_fraktion | TYPE STANDARD TABLE OF J_7LKB3, " | |||
| lv_land1 | TYPE J_7LE01-LAND1, " | |||
| lv_bukrs | TYPE J_7LP01-BUKRS, " | |||
| lv_plvrs | TYPE J_7LP01-PLVRS, " | |||
| lv_sokoa | TYPE J_7LP02-SOKOA, " | |||
| lv_stofe | TYPE J_7LP02-STOFE, " | |||
| lv_stofi | TYPE J_7LRSTOFI, " | |||
| lv_vflkl | TYPE J_7LP02-VFLKL. " |
|   CALL FUNCTION 'J_7L_CUST4_FORMEL' "NOTRANSL: REA Formel für die Entgeltberechnung (Template) |
| EXPORTING | ||
| FORMEL | = lv_formel | |
| DATUM | = lv_datum | |
| STFKZ | = lv_stfkz | |
| FMENG | = lv_fmeng | |
| VRPNR | = lv_vrpnr | |
| VARIANTE | = lv_variante | |
| MEINS | = lv_meins | |
| ENTNR | = lv_entnr | |
| LAND1 | = lv_land1 | |
| BUKRS | = lv_bukrs | |
| PLVRS | = lv_plvrs | |
| SOKOA | = lv_sokoa | |
| STOFE | = lv_stofe | |
| STOFI | = lv_stofi | |
| VFLKL | = lv_vflkl | |
| CHANGING | ||
| ENTGE | = lv_entge | |
| TABLES | ||
| POSITION | = lt_position | |
| FRAKTION | = lt_fraktion | |
| EXCEPTIONS | ||
| FORMEL_ERROR = 1 | ||
| . " J_7L_CUST4_FORMEL | ||
ABAP code using 7.40 inline data declarations to call FM J_7L_CUST4_FORMEL
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 NETWE FROM J_7LV1P INTO @DATA(ld_entge). | ||||
| "SELECT single FORMEL FROM J_7LE01 INTO @DATA(ld_formel). | ||||
| "SELECT single DATUM FROM SY INTO @DATA(ld_datum). | ||||
| DATA(ld_datum) | = SY-DATUM. | |||
| "SELECT single STFKZ FROM J_7LE15 INTO @DATA(ld_stfkz). | ||||
| "SELECT single FMENG FROM J_7LKB2 INTO @DATA(ld_fmeng). | ||||
| DATA(ld_fmeng) | = 1. | |||
| "SELECT single VRPNR FROM J_7LV01 INTO @DATA(ld_vrpnr). | ||||
| "SELECT single MEINS FROM MARA INTO @DATA(ld_meins). | ||||
| "SELECT single ENTNR FROM J_7LE01 INTO @DATA(ld_entnr). | ||||
| "SELECT single LAND1 FROM J_7LE01 INTO @DATA(ld_land1). | ||||
| "SELECT single BUKRS FROM J_7LP01 INTO @DATA(ld_bukrs). | ||||
| "SELECT single PLVRS FROM J_7LP01 INTO @DATA(ld_plvrs). | ||||
| "SELECT single SOKOA FROM J_7LP02 INTO @DATA(ld_sokoa). | ||||
| "SELECT single STOFE FROM J_7LP02 INTO @DATA(ld_stofe). | ||||
| "SELECT single VFLKL FROM J_7LP02 INTO @DATA(ld_vflkl). | ||||
Search for further information about these or an SAP related objects