SAP BAPI_MTRREADDOC_UPLOAD Function Module for Upload Meter Reading Results









BAPI_MTRREADDOC_UPLOAD is a standard bapi mtrreaddoc upload SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Upload Meter Reading Results 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 bapi mtrreaddoc upload FM, simply by entering the name BAPI_MTRREADDOC_UPLOAD into the relevant SAP transaction such as SE37 or SE38.

Function Group: MTRREADDOC
Program Name: SAPLMTRREADDOC
Main Program: SAPLMTRREADDOC
Appliation area: E
Release date: 05-Feb-1999
Mode(Normal, Remote etc): Remote-Enabled
Update:



Function BAPI_MTRREADDOC_UPLOAD 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 'BAPI_MTRREADDOC_UPLOAD'"Upload Meter Reading Results
EXPORTING
* X_USE_OPEN_LOG = ' ' "Indicator: Use Open Log for Messages
* X_AUTHORITY_MTREAD_CHECK = ' ' "Indicator: Execute Authorization Check

TABLES
* METERREADINGRESULTS = "Table of Uploaded Meter Reading Results
* METEREADINGRESCHANGE = "BAPI Upload Structure for MR Document
* METERREADINGRESUPDATE = "BAPI Upload Structure for Meter Reading Document (Update)
* RETURN = "Table of Return Parameters (Code, Text)
* EXTENSIONIN = "
* EOSBUPLOADDATA = "On-site Billing: Upload Data
.



IMPORTING Parameters details for BAPI_MTRREADDOC_UPLOAD

X_USE_OPEN_LOG - Indicator: Use Open Log for Messages

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

X_AUTHORITY_MTREAD_CHECK - Indicator: Execute Authorization Check

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

TABLES Parameters details for BAPI_MTRREADDOC_UPLOAD

METERREADINGRESULTS - Table of Uploaded Meter Reading Results

Data type: BAPIEABLU
Optional: Yes
Call by Reference: Yes

METEREADINGRESCHANGE - BAPI Upload Structure for MR Document

Data type: BAPIEABLUCHANGE
Optional: Yes
Call by Reference: Yes

METERREADINGRESUPDATE - BAPI Upload Structure for Meter Reading Document (Update)

Data type: BAPIEABLUUPDATE
Optional: Yes
Call by Reference: Yes

RETURN - Table of Return Parameters (Code, Text)

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

EXTENSIONIN -

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

EOSBUPLOADDATA - On-site Billing: Upload Data

Data type: BAPIOSBDATA
Optional: Yes
Call by Reference: Yes

Copy and paste ABAP code example for BAPI_MTRREADDOC_UPLOAD 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_x_use_open_log  TYPE KENNZX, "   SPACE
lt_meterreadingresults  TYPE STANDARD TABLE OF BAPIEABLU, "   
lt_metereadingreschange  TYPE STANDARD TABLE OF BAPIEABLUCHANGE, "   
lv_x_authority_mtread_check  TYPE KENNZX, "   SPACE
lt_meterreadingresupdate  TYPE STANDARD TABLE OF BAPIEABLUUPDATE, "   
lt_return  TYPE STANDARD TABLE OF BAPIRETURN1, "   
lt_extensionin  TYPE STANDARD TABLE OF BAPIPAREX, "   
lt_eosbuploaddata  TYPE STANDARD TABLE OF BAPIOSBDATA. "   

  CALL FUNCTION 'BAPI_MTRREADDOC_UPLOAD'  "Upload Meter Reading Results
    EXPORTING
         X_USE_OPEN_LOG = lv_x_use_open_log
         X_AUTHORITY_MTREAD_CHECK = lv_x_authority_mtread_check
    TABLES
         METERREADINGRESULTS = lt_meterreadingresults
         METEREADINGRESCHANGE = lt_metereadingreschange
         METERREADINGRESUPDATE = lt_meterreadingresupdate
         RETURN = lt_return
         EXTENSIONIN = lt_extensionin
         EOSBUPLOADDATA = lt_eosbuploaddata
. " BAPI_MTRREADDOC_UPLOAD




ABAP code using 7.40 inline data declarations to call FM BAPI_MTRREADDOC_UPLOAD

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_x_use_open_log) = ' '.
 
 
 
DATA(ld_x_authority_mtread_check) = ' '.
 
 
 
 
 


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!