SAP NOR3_CREATE_ASSET Function Module for driver for meta_create_asset
NOR3_CREATE_ASSET is a standard nor3 create asset SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for driver for meta_create_asset 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 nor3 create asset FM, simply by entering the name NOR3_CREATE_ASSET into the relevant SAP transaction such as SE37 or SE38.
Function Group: BBP_BD_DRIVER_NOR3
Program Name: SAPLBBP_BD_DRIVER_NOR3
Main Program: SAPLBBP_BD_DRIVER_NOR3
Appliation area: M
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function NOR3_CREATE_ASSET 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 'NOR3_CREATE_ASSET'"driver for meta_create_asset.
EXPORTING
ASSET_CLASS = "class of asset to be created
COMP_CODE = "company code for which asset is created
QUANTITY = "number of assets to be created
* TXT50 = "description (50 chars, optional)
* ACC_RECORD = "Kontierung
TABLES
ASSET_TAB = "table of assets created (result)
* CONTROL_RECORD = "
EXCEPTIONS
ASSET_NOT_CREATED = 1 ASSET_CLASS_NOT_VALID = 2 COMPANY_CODE_NOT_VALID = 3 CREATE_ERROR = 4
IMPORTING Parameters details for NOR3_CREATE_ASSET
ASSET_CLASS - class of asset to be created
Data type: CHAR8Optional: No
Call by Reference: No ( called with pass by value option)
COMP_CODE - company code for which asset is created
Data type: BUKRSOptional: No
Call by Reference: No ( called with pass by value option)
QUANTITY - number of assets to be created
Data type: BAPIEBKN-PREQ_QTYOptional: No
Call by Reference: No ( called with pass by value option)
TXT50 - description (50 chars, optional)
Data type: CHAR50Optional: Yes
Call by Reference: No ( called with pass by value option)
ACC_RECORD - Kontierung
Data type: BBP_PDS_ACCOptional: Yes
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for NOR3_CREATE_ASSET
ASSET_TAB - table of assets created (result)
Data type: BBP_ACR_COOptional: No
Call by Reference: No ( called with pass by value option)
CONTROL_RECORD -
Data type: BBP_CONTROL_RECORDOptional: Yes
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
ASSET_NOT_CREATED - error creating assets
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
ASSET_CLASS_NOT_VALID - asset class does not exist in backend
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
COMPANY_CODE_NOT_VALID - company code does not exist in backend
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
CREATE_ERROR - message id type e received from func. module
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for NOR3_CREATE_ASSET 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: | ||||
| lt_asset_tab | TYPE STANDARD TABLE OF BBP_ACR_CO, " | |||
| lv_asset_class | TYPE CHAR8, " | |||
| lv_asset_not_created | TYPE CHAR8, " | |||
| lv_comp_code | TYPE BUKRS, " | |||
| lt_control_record | TYPE STANDARD TABLE OF BBP_CONTROL_RECORD, " | |||
| lv_asset_class_not_valid | TYPE BBP_CONTROL_RECORD, " | |||
| lv_quantity | TYPE BAPIEBKN-PREQ_QTY, " | |||
| lv_company_code_not_valid | TYPE BAPIEBKN, " | |||
| lv_txt50 | TYPE CHAR50, " | |||
| lv_create_error | TYPE CHAR50, " | |||
| lv_acc_record | TYPE BBP_PDS_ACC. " |
|   CALL FUNCTION 'NOR3_CREATE_ASSET' "driver for meta_create_asset |
| EXPORTING | ||
| ASSET_CLASS | = lv_asset_class | |
| COMP_CODE | = lv_comp_code | |
| QUANTITY | = lv_quantity | |
| TXT50 | = lv_txt50 | |
| ACC_RECORD | = lv_acc_record | |
| TABLES | ||
| ASSET_TAB | = lt_asset_tab | |
| CONTROL_RECORD | = lt_control_record | |
| EXCEPTIONS | ||
| ASSET_NOT_CREATED = 1 | ||
| ASSET_CLASS_NOT_VALID = 2 | ||
| COMPANY_CODE_NOT_VALID = 3 | ||
| CREATE_ERROR = 4 | ||
| . " NOR3_CREATE_ASSET | ||
ABAP code using 7.40 inline data declarations to call FM NOR3_CREATE_ASSET
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 PREQ_QTY FROM BAPIEBKN INTO @DATA(ld_quantity). | ||||
Search for further information about these or an SAP related objects