SAP BAPIADDREMPUS_SIMULATECREATION Function Module for Simulation: Create Employee Address
BAPIADDREMPUS_SIMULATECREATION is a standard bapiaddrempus simulatecreation SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Simulation: Create Employee Address 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 bapiaddrempus simulatecreation FM, simply by entering the name BAPIADDREMPUS_SIMULATECREATION into the relevant SAP transaction such as SE37 or SE38.
Function Group: PADR_US
Program Name: SAPLPADR_US
Main Program:
Appliation area: P
Release date: 23-Apr-1998
Mode(Normal, Remote etc): Remote-Enabled
Update:
Function BAPIADDREMPUS_SIMULATECREATION 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 'BAPIADDREMPUS_SIMULATECREATION'"Simulation: Create Employee Address.
EXPORTING
EMPLOYEENUMBER = "Personnel Number
* POSTALCODECITY = "Zip Code
* STATE = "Region
* COUNTRY = "Country Key
* TELEPHONENUMBER = "Telephone Number
* COMMTYPE1 = "
* COMMNUMBER1 = "
* COMMTYPE2 = "
* COMMNUMBER2 = "
* COMMTYPE3 = "
* COMMNUMBER3 = "
VALIDITYBEGIN = "Validity Start Date
* COMMTYPE4 = "
* COMMNUMBER4 = "
* COMMTYPE5 = "
* COMMNUMBER5 = "
* COMMTYPE6 = "
* COMMNUMBER6 = "
* NOCOMMIT = "Commit Control on BAPI Interface
VALIDITYEND = "Validity End Date
ADDRESSTYPE = "Subtype
* CONAME = "C/O Name
* STREETANDHOUSENO = "Street and House Number
* SCNDADDRESSLINE = "2nd Address Line
* CITY = "City
* DISTRICT = "District
IMPORTING
RETURN = "Return Parameter Structure
EMPLOYEENUMBER = "Personnel Number
SUBTYPE = "Subtype
OBJECTID = "Object Identification
LOCKINDICATOR = "Lock Indicator for HR Master Record
VALIDITYBEGIN = "Validity Start Date
VALIDITYEND = "Validity End Date
RECORDNUMBER = "Infotype Record Number
IMPORTING Parameters details for BAPIADDREMPUS_SIMULATECREATION
EMPLOYEENUMBER - Personnel Number
Data type: BAPIP0006-PERNROptional: No
Call by Reference: No ( called with pass by value option)
POSTALCODECITY - Zip Code
Data type: BAPIP0006-PSTLZOptional: Yes
Call by Reference: No ( called with pass by value option)
STATE - Region
Data type: BAPIP0006-STATEOptional: Yes
Call by Reference: No ( called with pass by value option)
COUNTRY - Country Key
Data type: BAPIP0006-LAND1Optional: Yes
Call by Reference: No ( called with pass by value option)
TELEPHONENUMBER - Telephone Number
Data type: BAPIP0006-TELNROptional: Yes
Call by Reference: No ( called with pass by value option)
COMMTYPE1 -
Data type: BAPIP0006LUS-COMMTYPE1Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMNUMBER1 -
Data type: BAPIP0006LUS-COMMNUMBER1Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMTYPE2 -
Data type: BAPIP0006LUS-COMMTYPE2Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMNUMBER2 -
Data type: BAPIP0006LUS-COMMNUMBER2Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMTYPE3 -
Data type: BAPIP0006LUS-COMMTYPE3Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMNUMBER3 -
Data type: BAPIP0006LUS-COMMNUMBER3Optional: Yes
Call by Reference: No ( called with pass by value option)
VALIDITYBEGIN - Validity Start Date
Data type: BAPIP0006-BEGDAOptional: No
Call by Reference: No ( called with pass by value option)
COMMTYPE4 -
Data type: BAPIP0006LUS-COMMTYPE4Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMNUMBER4 -
Data type: BAPIP0006LUS-COMMNUMBER4Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMTYPE5 -
Data type: BAPIP0006LUS-COMMTYPE5Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMNUMBER5 -
Data type: BAPIP0006LUS-COMMNUMBER5Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMTYPE6 -
Data type: BAPIP0006LUS-COMMTYPE6Optional: Yes
Call by Reference: No ( called with pass by value option)
COMMNUMBER6 -
Data type: BAPIP0006LUS-COMMNUMBER6Optional: Yes
Call by Reference: No ( called with pass by value option)
NOCOMMIT - Commit Control on BAPI Interface
Data type: BAPI_STAND-NO_COMMITOptional: Yes
Call by Reference: No ( called with pass by value option)
VALIDITYEND - Validity End Date
Data type: BAPIP0006-ENDDAOptional: No
Call by Reference: No ( called with pass by value option)
ADDRESSTYPE - Subtype
Data type: BAPIP0006-SUBTYOptional: No
Call by Reference: No ( called with pass by value option)
CONAME - C/O Name
Data type: BAPIP0006-NAME2Optional: Yes
Call by Reference: No ( called with pass by value option)
STREETANDHOUSENO - Street and House Number
Data type: BAPIP0006-STRASOptional: Yes
Call by Reference: No ( called with pass by value option)
SCNDADDRESSLINE - 2nd Address Line
Data type: BAPIP0006-LOCATOptional: Yes
Call by Reference: No ( called with pass by value option)
CITY - City
Data type: BAPIP0006-ORT01Optional: Yes
Call by Reference: No ( called with pass by value option)
DISTRICT - District
Data type: BAPIP0006-ORT02Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for BAPIADDREMPUS_SIMULATECREATION
RETURN - Return Parameter Structure
Data type: BAPIRETURN1Optional: No
Call by Reference: No ( called with pass by value option)
EMPLOYEENUMBER - Personnel Number
Data type: BAPIP0006-PERNROptional: No
Call by Reference: No ( called with pass by value option)
SUBTYPE - Subtype
Data type: BAPIP0006-SUBTYOptional: No
Call by Reference: No ( called with pass by value option)
OBJECTID - Object Identification
Data type: BAPIP0006-OBJPSOptional: No
Call by Reference: No ( called with pass by value option)
LOCKINDICATOR - Lock Indicator for HR Master Record
Data type: BAPIP0006-SPRPSOptional: No
Call by Reference: No ( called with pass by value option)
VALIDITYBEGIN - Validity Start Date
Data type: BAPIP0006-BEGDAOptional: No
Call by Reference: No ( called with pass by value option)
VALIDITYEND - Validity End Date
Data type: BAPIP0006-ENDDAOptional: No
Call by Reference: No ( called with pass by value option)
RECORDNUMBER - Infotype Record Number
Data type: BAPIP0006-SEQNROptional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for BAPIADDREMPUS_SIMULATECREATION 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_return | TYPE BAPIRETURN1, " | |||
lv_employeenumber | TYPE BAPIP0006-PERNR, " | |||
lv_postalcodecity | TYPE BAPIP0006-PSTLZ, " | |||
lv_state | TYPE BAPIP0006-STATE, " | |||
lv_country | TYPE BAPIP0006-LAND1, " | |||
lv_telephonenumber | TYPE BAPIP0006-TELNR, " | |||
lv_commtype1 | TYPE BAPIP0006LUS-COMMTYPE1, " | |||
lv_commnumber1 | TYPE BAPIP0006LUS-COMMNUMBER1, " | |||
lv_commtype2 | TYPE BAPIP0006LUS-COMMTYPE2, " | |||
lv_commnumber2 | TYPE BAPIP0006LUS-COMMNUMBER2, " | |||
lv_commtype3 | TYPE BAPIP0006LUS-COMMTYPE3, " | |||
lv_commnumber3 | TYPE BAPIP0006LUS-COMMNUMBER3, " | |||
lv_validitybegin | TYPE BAPIP0006-BEGDA, " | |||
lv_employeenumber | TYPE BAPIP0006-PERNR, " | |||
lv_commtype4 | TYPE BAPIP0006LUS-COMMTYPE4, " | |||
lv_commnumber4 | TYPE BAPIP0006LUS-COMMNUMBER4, " | |||
lv_commtype5 | TYPE BAPIP0006LUS-COMMTYPE5, " | |||
lv_commnumber5 | TYPE BAPIP0006LUS-COMMNUMBER5, " | |||
lv_commtype6 | TYPE BAPIP0006LUS-COMMTYPE6, " | |||
lv_commnumber6 | TYPE BAPIP0006LUS-COMMNUMBER6, " | |||
lv_nocommit | TYPE BAPI_STAND-NO_COMMIT, " | |||
lv_subtype | TYPE BAPIP0006-SUBTY, " | |||
lv_validityend | TYPE BAPIP0006-ENDDA, " | |||
lv_objectid | TYPE BAPIP0006-OBJPS, " | |||
lv_addresstype | TYPE BAPIP0006-SUBTY, " | |||
lv_coname | TYPE BAPIP0006-NAME2, " | |||
lv_lockindicator | TYPE BAPIP0006-SPRPS, " | |||
lv_validitybegin | TYPE BAPIP0006-BEGDA, " | |||
lv_streetandhouseno | TYPE BAPIP0006-STRAS, " | |||
lv_validityend | TYPE BAPIP0006-ENDDA, " | |||
lv_scndaddressline | TYPE BAPIP0006-LOCAT, " | |||
lv_city | TYPE BAPIP0006-ORT01, " | |||
lv_recordnumber | TYPE BAPIP0006-SEQNR, " | |||
lv_district | TYPE BAPIP0006-ORT02. " |
  CALL FUNCTION 'BAPIADDREMPUS_SIMULATECREATION' "Simulation: Create Employee Address |
EXPORTING | ||
EMPLOYEENUMBER | = lv_employeenumber | |
POSTALCODECITY | = lv_postalcodecity | |
STATE | = lv_state | |
COUNTRY | = lv_country | |
TELEPHONENUMBER | = lv_telephonenumber | |
COMMTYPE1 | = lv_commtype1 | |
COMMNUMBER1 | = lv_commnumber1 | |
COMMTYPE2 | = lv_commtype2 | |
COMMNUMBER2 | = lv_commnumber2 | |
COMMTYPE3 | = lv_commtype3 | |
COMMNUMBER3 | = lv_commnumber3 | |
VALIDITYBEGIN | = lv_validitybegin | |
COMMTYPE4 | = lv_commtype4 | |
COMMNUMBER4 | = lv_commnumber4 | |
COMMTYPE5 | = lv_commtype5 | |
COMMNUMBER5 | = lv_commnumber5 | |
COMMTYPE6 | = lv_commtype6 | |
COMMNUMBER6 | = lv_commnumber6 | |
NOCOMMIT | = lv_nocommit | |
VALIDITYEND | = lv_validityend | |
ADDRESSTYPE | = lv_addresstype | |
CONAME | = lv_coname | |
STREETANDHOUSENO | = lv_streetandhouseno | |
SCNDADDRESSLINE | = lv_scndaddressline | |
CITY | = lv_city | |
DISTRICT | = lv_district | |
IMPORTING | ||
RETURN | = lv_return | |
EMPLOYEENUMBER | = lv_employeenumber | |
SUBTYPE | = lv_subtype | |
OBJECTID | = lv_objectid | |
LOCKINDICATOR | = lv_lockindicator | |
VALIDITYBEGIN | = lv_validitybegin | |
VALIDITYEND | = lv_validityend | |
RECORDNUMBER | = lv_recordnumber | |
. " BAPIADDREMPUS_SIMULATECREATION |
ABAP code using 7.40 inline data declarations to call FM BAPIADDREMPUS_SIMULATECREATION
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 PERNR FROM BAPIP0006 INTO @DATA(ld_employeenumber). | ||||
"SELECT single PSTLZ FROM BAPIP0006 INTO @DATA(ld_postalcodecity). | ||||
"SELECT single STATE FROM BAPIP0006 INTO @DATA(ld_state). | ||||
"SELECT single LAND1 FROM BAPIP0006 INTO @DATA(ld_country). | ||||
"SELECT single TELNR FROM BAPIP0006 INTO @DATA(ld_telephonenumber). | ||||
"SELECT single COMMTYPE1 FROM BAPIP0006LUS INTO @DATA(ld_commtype1). | ||||
"SELECT single COMMNUMBER1 FROM BAPIP0006LUS INTO @DATA(ld_commnumber1). | ||||
"SELECT single COMMTYPE2 FROM BAPIP0006LUS INTO @DATA(ld_commtype2). | ||||
"SELECT single COMMNUMBER2 FROM BAPIP0006LUS INTO @DATA(ld_commnumber2). | ||||
"SELECT single COMMTYPE3 FROM BAPIP0006LUS INTO @DATA(ld_commtype3). | ||||
"SELECT single COMMNUMBER3 FROM BAPIP0006LUS INTO @DATA(ld_commnumber3). | ||||
"SELECT single BEGDA FROM BAPIP0006 INTO @DATA(ld_validitybegin). | ||||
"SELECT single PERNR FROM BAPIP0006 INTO @DATA(ld_employeenumber). | ||||
"SELECT single COMMTYPE4 FROM BAPIP0006LUS INTO @DATA(ld_commtype4). | ||||
"SELECT single COMMNUMBER4 FROM BAPIP0006LUS INTO @DATA(ld_commnumber4). | ||||
"SELECT single COMMTYPE5 FROM BAPIP0006LUS INTO @DATA(ld_commtype5). | ||||
"SELECT single COMMNUMBER5 FROM BAPIP0006LUS INTO @DATA(ld_commnumber5). | ||||
"SELECT single COMMTYPE6 FROM BAPIP0006LUS INTO @DATA(ld_commtype6). | ||||
"SELECT single COMMNUMBER6 FROM BAPIP0006LUS INTO @DATA(ld_commnumber6). | ||||
"SELECT single NO_COMMIT FROM BAPI_STAND INTO @DATA(ld_nocommit). | ||||
"SELECT single SUBTY FROM BAPIP0006 INTO @DATA(ld_subtype). | ||||
"SELECT single ENDDA FROM BAPIP0006 INTO @DATA(ld_validityend). | ||||
"SELECT single OBJPS FROM BAPIP0006 INTO @DATA(ld_objectid). | ||||
"SELECT single SUBTY FROM BAPIP0006 INTO @DATA(ld_addresstype). | ||||
"SELECT single NAME2 FROM BAPIP0006 INTO @DATA(ld_coname). | ||||
"SELECT single SPRPS FROM BAPIP0006 INTO @DATA(ld_lockindicator). | ||||
"SELECT single BEGDA FROM BAPIP0006 INTO @DATA(ld_validitybegin). | ||||
"SELECT single STRAS FROM BAPIP0006 INTO @DATA(ld_streetandhouseno). | ||||
"SELECT single ENDDA FROM BAPIP0006 INTO @DATA(ld_validityend). | ||||
"SELECT single LOCAT FROM BAPIP0006 INTO @DATA(ld_scndaddressline). | ||||
"SELECT single ORT01 FROM BAPIP0006 INTO @DATA(ld_city). | ||||
"SELECT single SEQNR FROM BAPIP0006 INTO @DATA(ld_recordnumber). | ||||
"SELECT single ORT02 FROM BAPIP0006 INTO @DATA(ld_district). | ||||
Search for further information about these or an SAP related objects