SAP Function Modules

ALE_MATERIAL_MAINTAINDATA_RT SAP Function module







ALE_MATERIAL_MAINTAINDATA_RT is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name ALE_MATERIAL_MAINTAINDATA_RT into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: MGWA
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM ALE_MATERIAL_MAINTAINDATA_RT - ALE MATERIAL MAINTAINDATA RT





CALL FUNCTION 'ALE_MATERIAL_MAINTAINDATA_RT' "
  EXPORTING
    headdata =                  " bapie1mathead  Header segment with control information
*   obj_type = 'BUS1001001'     " serial-obj_type
*   serial_id = '0'             " serial-chnum
  TABLES
*   variantskeys =              " bapie1varkey  List of variants for configurable material
*   characteristicvalue =       " bapie1ausprt  Characteristic value assignment data
*   characteristicvaluex =      " bapie1ausprtx  Information on update for CHARACTERISTICVALUE
*   clientdata =                " bapie1marart  Client-specific material data
*   clientdatax =               " bapie1marartx  Information on Update for CLIENTDATA
*   clientext =                 " bapie1maraextrt  Customer-defined client-specific material data
*   clientextx =                " bapie1maraextrtx  Information on update for CLIENTEXT
*   addnlclientdata =           " bapie1maw1rt  Additional client-specific material data
*   addnlclientdatax =          " bapie1maw1rtx  Information on update for ADDNLCLIENTDATA
*   materialdescription =       " bapie1maktrt  Material Descriptions
*   plantdata =                 " bapie1marcrt  Plant-specific material data
*   plantdatax =                " bapie1marcrtx  Information on Update for PLANTDATA
*   plantext =                  " bapie1marcextrt  Customer-defined plant-specific material data
*   plantextx =                 " bapie1marcextrtx  Information on update for PLANTEXT
*   forecastparameters =        " bapie1mpoprt  Forecast Parameters
*   forecastparametersx =       " bapie1mpoprtx  Information on Update for FORECASTDATA
*   forecastvalues =            " bapie1mprwrt  Forecast Values
*   totalconsumption =          " bapie1mvegrt  Total consumption
*   unplndconsumption =         " bapie1mveurt  Unplanned consumption
*   planningdata =              " bapie1mpgdrt  Planning data
*   planningdatax =             " bapie1mpgdrtx  Information on Update for PLANNINGDATA
*   storagelocationdata =       " bapie1mardrt  Storage-location-specific material data
*   storagelocationdatax =      " bapie1mardrtx  Information on Update for STORAGELOCATIONDATA
*   storagelocationext =        " bapie1mardextrt  Customer-defined storage-location-specific material data
*   storagelocationextx =       " bapie1mardextrtx  Information on update for STORAGELOCATIONEXT
*   unitsofmeasure =            " bapie1marmrt  Units of Measure
*   unitsofmeasurex =           " bapie1marmrtx  Information on Update for UNITSOFMEASURE
*   unitofmeasuretexts =        " bapie1mamtrt  Texts specific to the unit of measure
*   internationalartnos =       " bapie1meanrt  International Article Numbers (EANs)
*   vendorean =                 " bapie1mleart  Vendor-Specific EANs
*   layoutmoduleassgmt =        " bapie1malgrt  Assignment of layout modules to materials
*   layoutmoduleassgmtx =       " bapie1malgrtx  Information on update for LAYOUTMODULEASSGMT
*   taxclassifications =        " bapie1mlanrt  Tax classifications
*   valuationdata =             " bapie1mbewrt  Valuation data
*   valuationdatax =            " bapie1mbewrtx  Information on Update for VALUATIONDATA
*   valuationext =              " bapie1mbewextrt  Customer-defined valuation data
*   valuationextx =             " bapie1mbewextrtx  Information on update for VALUATIONEXT
*   warehousenumberdata =       " bapie1mlgnrt  Warehouse-number-specific material data
*   warehousenumberdatax =      " bapie1mlgnrtx  Information on Update for WAREHOUSEDATA
*   warehousenumberext =        " bapie1mlgnextrt  Customer-defined warehouse-number-specific material data
*   warehousenumberextx =       " bapie1mlgnextrtx  Information on update for WAREHOUSENUMBEREXT
*   storagetypedata =           " bapie1mlgtrt  Storage-type-specific material data
*   storagetypedatax =          " bapie1mlgtrtx  Information on Update for STORAGETYPEDATA
*   storagetypeext =            " bapie1mlgtextrt  Customer-defined storage-type-specific material data
*   storagetypeextx =           " bapie1mlgtextrtx  Information on update for STORAGETYPEEXT
*   salesdata =                 " bapie1mvkert  Sales Data
*   salesdatax =                " bapie1mvkertx  Information on Update for SALESDATA
*   salesext =                  " bapie1mvkeextrt  Customer-defined sales data
*   salesextx =                 " bapie1mvkeextrtx  Information on update for SALESEXT
*   posdata =                   " bapie1wlk2rt  POS Data
*   posdatax =                  " bapie1wlk2rtx  Information on update for POSDATA
*   posext =                    " bapie1wlk2extrt  Customer-defined POS data
*   posextx =                   " bapie1wlk2extrtx  Information on update for POSEXT
*   materiallongtext =          " bapie1mltxrt  Long Texts
*   plantkeys =                 " bapie1wrkkey  List of other plants
*   storagelocationkeys =       " bapie1lgokey  List of other storage locations
*   distrchainkeys =            " bapie1vtlkey  List of other distribution chains
*   warehousenokeys =           " bapie1lgnkey  List of other warehouse numbers
*   storagetypekeys =           " bapie1lgtkey  List of other storage types
*   valuationtypekeys =         " bapie1bwakey  List of other valuation types
*   textilecomponents =         " bapitextlcomp
*   fibercodes =                " bapitextlfibr
    receivers =                 " bdi_logsys
*   communication_documents =   " swotobjid
*   application_objects =       " swotobjid
  EXCEPTIONS
    ERROR_CREATING_IDOCS = 1    "
    .  "  ALE_MATERIAL_MAINTAINDATA_RT

ABAP code example for Function Module ALE_MATERIAL_MAINTAINDATA_RT





The ABAP code below is a full code listing to execute function module ALE_MATERIAL_MAINTAINDATA_RT including all data declarations. The code uses 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 original method of declaring data variables up front. 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).

DATA:
it_variantskeys  TYPE STANDARD TABLE OF BAPIE1VARKEY,"TABLES PARAM
wa_variantskeys  LIKE LINE OF it_variantskeys ,
it_characteristicvalue  TYPE STANDARD TABLE OF BAPIE1AUSPRT,"TABLES PARAM
wa_characteristicvalue  LIKE LINE OF it_characteristicvalue ,
it_characteristicvaluex  TYPE STANDARD TABLE OF BAPIE1AUSPRTX,"TABLES PARAM
wa_characteristicvaluex  LIKE LINE OF it_characteristicvaluex ,
it_clientdata  TYPE STANDARD TABLE OF BAPIE1MARART,"TABLES PARAM
wa_clientdata  LIKE LINE OF it_clientdata ,
it_clientdatax  TYPE STANDARD TABLE OF BAPIE1MARARTX,"TABLES PARAM
wa_clientdatax  LIKE LINE OF it_clientdatax ,
it_clientext  TYPE STANDARD TABLE OF BAPIE1MARAEXTRT,"TABLES PARAM
wa_clientext  LIKE LINE OF it_clientext ,
it_clientextx  TYPE STANDARD TABLE OF BAPIE1MARAEXTRTX,"TABLES PARAM
wa_clientextx  LIKE LINE OF it_clientextx ,
it_addnlclientdata  TYPE STANDARD TABLE OF BAPIE1MAW1RT,"TABLES PARAM
wa_addnlclientdata  LIKE LINE OF it_addnlclientdata ,
it_addnlclientdatax  TYPE STANDARD TABLE OF BAPIE1MAW1RTX,"TABLES PARAM
wa_addnlclientdatax  LIKE LINE OF it_addnlclientdatax ,
it_materialdescription  TYPE STANDARD TABLE OF BAPIE1MAKTRT,"TABLES PARAM
wa_materialdescription  LIKE LINE OF it_materialdescription ,
it_plantdata  TYPE STANDARD TABLE OF BAPIE1MARCRT,"TABLES PARAM
wa_plantdata  LIKE LINE OF it_plantdata ,
it_plantdatax  TYPE STANDARD TABLE OF BAPIE1MARCRTX,"TABLES PARAM
wa_plantdatax  LIKE LINE OF it_plantdatax ,
it_plantext  TYPE STANDARD TABLE OF BAPIE1MARCEXTRT,"TABLES PARAM
wa_plantext  LIKE LINE OF it_plantext ,
it_plantextx  TYPE STANDARD TABLE OF BAPIE1MARCEXTRTX,"TABLES PARAM
wa_plantextx  LIKE LINE OF it_plantextx ,
it_forecastparameters  TYPE STANDARD TABLE OF BAPIE1MPOPRT,"TABLES PARAM
wa_forecastparameters  LIKE LINE OF it_forecastparameters ,
it_forecastparametersx  TYPE STANDARD TABLE OF BAPIE1MPOPRTX,"TABLES PARAM
wa_forecastparametersx  LIKE LINE OF it_forecastparametersx ,
it_forecastvalues  TYPE STANDARD TABLE OF BAPIE1MPRWRT,"TABLES PARAM
wa_forecastvalues  LIKE LINE OF it_forecastvalues ,
it_totalconsumption  TYPE STANDARD TABLE OF BAPIE1MVEGRT,"TABLES PARAM
wa_totalconsumption  LIKE LINE OF it_totalconsumption ,
it_unplndconsumption  TYPE STANDARD TABLE OF BAPIE1MVEURT,"TABLES PARAM
wa_unplndconsumption  LIKE LINE OF it_unplndconsumption ,
it_planningdata  TYPE STANDARD TABLE OF BAPIE1MPGDRT,"TABLES PARAM
wa_planningdata  LIKE LINE OF it_planningdata ,
it_planningdatax  TYPE STANDARD TABLE OF BAPIE1MPGDRTX,"TABLES PARAM
wa_planningdatax  LIKE LINE OF it_planningdatax ,
it_storagelocationdata  TYPE STANDARD TABLE OF BAPIE1MARDRT,"TABLES PARAM
wa_storagelocationdata  LIKE LINE OF it_storagelocationdata ,
it_storagelocationdatax  TYPE STANDARD TABLE OF BAPIE1MARDRTX,"TABLES PARAM
wa_storagelocationdatax  LIKE LINE OF it_storagelocationdatax ,
it_storagelocationext  TYPE STANDARD TABLE OF BAPIE1MARDEXTRT,"TABLES PARAM
wa_storagelocationext  LIKE LINE OF it_storagelocationext ,
it_storagelocationextx  TYPE STANDARD TABLE OF BAPIE1MARDEXTRTX,"TABLES PARAM
wa_storagelocationextx  LIKE LINE OF it_storagelocationextx ,
it_unitsofmeasure  TYPE STANDARD TABLE OF BAPIE1MARMRT,"TABLES PARAM
wa_unitsofmeasure  LIKE LINE OF it_unitsofmeasure ,
it_unitsofmeasurex  TYPE STANDARD TABLE OF BAPIE1MARMRTX,"TABLES PARAM
wa_unitsofmeasurex  LIKE LINE OF it_unitsofmeasurex ,
it_unitofmeasuretexts  TYPE STANDARD TABLE OF BAPIE1MAMTRT,"TABLES PARAM
wa_unitofmeasuretexts  LIKE LINE OF it_unitofmeasuretexts ,
it_internationalartnos  TYPE STANDARD TABLE OF BAPIE1MEANRT,"TABLES PARAM
wa_internationalartnos  LIKE LINE OF it_internationalartnos ,
it_vendorean  TYPE STANDARD TABLE OF BAPIE1MLEART,"TABLES PARAM
wa_vendorean  LIKE LINE OF it_vendorean ,
it_layoutmoduleassgmt  TYPE STANDARD TABLE OF BAPIE1MALGRT,"TABLES PARAM
wa_layoutmoduleassgmt  LIKE LINE OF it_layoutmoduleassgmt ,
it_layoutmoduleassgmtx  TYPE STANDARD TABLE OF BAPIE1MALGRTX,"TABLES PARAM
wa_layoutmoduleassgmtx  LIKE LINE OF it_layoutmoduleassgmtx ,
it_taxclassifications  TYPE STANDARD TABLE OF BAPIE1MLANRT,"TABLES PARAM
wa_taxclassifications  LIKE LINE OF it_taxclassifications ,
it_valuationdata  TYPE STANDARD TABLE OF BAPIE1MBEWRT,"TABLES PARAM
wa_valuationdata  LIKE LINE OF it_valuationdata ,
it_valuationdatax  TYPE STANDARD TABLE OF BAPIE1MBEWRTX,"TABLES PARAM
wa_valuationdatax  LIKE LINE OF it_valuationdatax ,
it_valuationext  TYPE STANDARD TABLE OF BAPIE1MBEWEXTRT,"TABLES PARAM
wa_valuationext  LIKE LINE OF it_valuationext ,
it_valuationextx  TYPE STANDARD TABLE OF BAPIE1MBEWEXTRTX,"TABLES PARAM
wa_valuationextx  LIKE LINE OF it_valuationextx ,
it_warehousenumberdata  TYPE STANDARD TABLE OF BAPIE1MLGNRT,"TABLES PARAM
wa_warehousenumberdata  LIKE LINE OF it_warehousenumberdata ,
it_warehousenumberdatax  TYPE STANDARD TABLE OF BAPIE1MLGNRTX,"TABLES PARAM
wa_warehousenumberdatax  LIKE LINE OF it_warehousenumberdatax ,
it_warehousenumberext  TYPE STANDARD TABLE OF BAPIE1MLGNEXTRT,"TABLES PARAM
wa_warehousenumberext  LIKE LINE OF it_warehousenumberext ,
it_warehousenumberextx  TYPE STANDARD TABLE OF BAPIE1MLGNEXTRTX,"TABLES PARAM
wa_warehousenumberextx  LIKE LINE OF it_warehousenumberextx ,
it_storagetypedata  TYPE STANDARD TABLE OF BAPIE1MLGTRT,"TABLES PARAM
wa_storagetypedata  LIKE LINE OF it_storagetypedata ,
it_storagetypedatax  TYPE STANDARD TABLE OF BAPIE1MLGTRTX,"TABLES PARAM
wa_storagetypedatax  LIKE LINE OF it_storagetypedatax ,
it_storagetypeext  TYPE STANDARD TABLE OF BAPIE1MLGTEXTRT,"TABLES PARAM
wa_storagetypeext  LIKE LINE OF it_storagetypeext ,
it_storagetypeextx  TYPE STANDARD TABLE OF BAPIE1MLGTEXTRTX,"TABLES PARAM
wa_storagetypeextx  LIKE LINE OF it_storagetypeextx ,
it_salesdata  TYPE STANDARD TABLE OF BAPIE1MVKERT,"TABLES PARAM
wa_salesdata  LIKE LINE OF it_salesdata ,
it_salesdatax  TYPE STANDARD TABLE OF BAPIE1MVKERTX,"TABLES PARAM
wa_salesdatax  LIKE LINE OF it_salesdatax ,
it_salesext  TYPE STANDARD TABLE OF BAPIE1MVKEEXTRT,"TABLES PARAM
wa_salesext  LIKE LINE OF it_salesext ,
it_salesextx  TYPE STANDARD TABLE OF BAPIE1MVKEEXTRTX,"TABLES PARAM
wa_salesextx  LIKE LINE OF it_salesextx ,
it_posdata  TYPE STANDARD TABLE OF BAPIE1WLK2RT,"TABLES PARAM
wa_posdata  LIKE LINE OF it_posdata ,
it_posdatax  TYPE STANDARD TABLE OF BAPIE1WLK2RTX,"TABLES PARAM
wa_posdatax  LIKE LINE OF it_posdatax ,
it_posext  TYPE STANDARD TABLE OF BAPIE1WLK2EXTRT,"TABLES PARAM
wa_posext  LIKE LINE OF it_posext ,
it_posextx  TYPE STANDARD TABLE OF BAPIE1WLK2EXTRTX,"TABLES PARAM
wa_posextx  LIKE LINE OF it_posextx ,
it_materiallongtext  TYPE STANDARD TABLE OF BAPIE1MLTXRT,"TABLES PARAM
wa_materiallongtext  LIKE LINE OF it_materiallongtext ,
it_plantkeys  TYPE STANDARD TABLE OF BAPIE1WRKKEY,"TABLES PARAM
wa_plantkeys  LIKE LINE OF it_plantkeys ,
it_storagelocationkeys  TYPE STANDARD TABLE OF BAPIE1LGOKEY,"TABLES PARAM
wa_storagelocationkeys  LIKE LINE OF it_storagelocationkeys ,
it_distrchainkeys  TYPE STANDARD TABLE OF BAPIE1VTLKEY,"TABLES PARAM
wa_distrchainkeys  LIKE LINE OF it_distrchainkeys ,
it_warehousenokeys  TYPE STANDARD TABLE OF BAPIE1LGNKEY,"TABLES PARAM
wa_warehousenokeys  LIKE LINE OF it_warehousenokeys ,
it_storagetypekeys  TYPE STANDARD TABLE OF BAPIE1LGTKEY,"TABLES PARAM
wa_storagetypekeys  LIKE LINE OF it_storagetypekeys ,
it_valuationtypekeys  TYPE STANDARD TABLE OF BAPIE1BWAKEY,"TABLES PARAM
wa_valuationtypekeys  LIKE LINE OF it_valuationtypekeys ,
it_textilecomponents  TYPE STANDARD TABLE OF BAPITEXTLCOMP,"TABLES PARAM
wa_textilecomponents  LIKE LINE OF it_textilecomponents ,
it_fibercodes  TYPE STANDARD TABLE OF BAPITEXTLFIBR,"TABLES PARAM
wa_fibercodes  LIKE LINE OF it_fibercodes ,
it_receivers  TYPE STANDARD TABLE OF BDI_LOGSYS,"TABLES PARAM
wa_receivers  LIKE LINE OF it_receivers ,
it_communication_documents  TYPE STANDARD TABLE OF SWOTOBJID,"TABLES PARAM
wa_communication_documents  LIKE LINE OF it_communication_documents ,
it_application_objects  TYPE STANDARD TABLE OF SWOTOBJID,"TABLES PARAM
wa_application_objects  LIKE LINE OF it_application_objects .

DATA(ld_headdata) = 'Check type of data required'.

DATA(ld_obj_type) = some text here

DATA(ld_serial_id) = Check type of data required

"populate fields of struture and append to itab
append wa_variantskeys to it_variantskeys.

"populate fields of struture and append to itab
append wa_characteristicvalue to it_characteristicvalue.

"populate fields of struture and append to itab
append wa_characteristicvaluex to it_characteristicvaluex.

"populate fields of struture and append to itab
append wa_clientdata to it_clientdata.

"populate fields of struture and append to itab
append wa_clientdatax to it_clientdatax.

"populate fields of struture and append to itab
append wa_clientext to it_clientext.

"populate fields of struture and append to itab
append wa_clientextx to it_clientextx.

"populate fields of struture and append to itab
append wa_addnlclientdata to it_addnlclientdata.

"populate fields of struture and append to itab
append wa_addnlclientdatax to it_addnlclientdatax.

"populate fields of struture and append to itab
append wa_materialdescription to it_materialdescription.

"populate fields of struture and append to itab
append wa_plantdata to it_plantdata.

"populate fields of struture and append to itab
append wa_plantdatax to it_plantdatax.

"populate fields of struture and append to itab
append wa_plantext to it_plantext.

"populate fields of struture and append to itab
append wa_plantextx to it_plantextx.

"populate fields of struture and append to itab
append wa_forecastparameters to it_forecastparameters.

"populate fields of struture and append to itab
append wa_forecastparametersx to it_forecastparametersx.

"populate fields of struture and append to itab
append wa_forecastvalues to it_forecastvalues.

"populate fields of struture and append to itab
append wa_totalconsumption to it_totalconsumption.

"populate fields of struture and append to itab
append wa_unplndconsumption to it_unplndconsumption.

"populate fields of struture and append to itab
append wa_planningdata to it_planningdata.

"populate fields of struture and append to itab
append wa_planningdatax to it_planningdatax.

"populate fields of struture and append to itab
append wa_storagelocationdata to it_storagelocationdata.

"populate fields of struture and append to itab
append wa_storagelocationdatax to it_storagelocationdatax.

"populate fields of struture and append to itab
append wa_storagelocationext to it_storagelocationext.

"populate fields of struture and append to itab
append wa_storagelocationextx to it_storagelocationextx.

"populate fields of struture and append to itab
append wa_unitsofmeasure to it_unitsofmeasure.

"populate fields of struture and append to itab
append wa_unitsofmeasurex to it_unitsofmeasurex.

"populate fields of struture and append to itab
append wa_unitofmeasuretexts to it_unitofmeasuretexts.

"populate fields of struture and append to itab
append wa_internationalartnos to it_internationalartnos.

"populate fields of struture and append to itab
append wa_vendorean to it_vendorean.

"populate fields of struture and append to itab
append wa_layoutmoduleassgmt to it_layoutmoduleassgmt.

"populate fields of struture and append to itab
append wa_layoutmoduleassgmtx to it_layoutmoduleassgmtx.

"populate fields of struture and append to itab
append wa_taxclassifications to it_taxclassifications.

"populate fields of struture and append to itab
append wa_valuationdata to it_valuationdata.

"populate fields of struture and append to itab
append wa_valuationdatax to it_valuationdatax.

"populate fields of struture and append to itab
append wa_valuationext to it_valuationext.

"populate fields of struture and append to itab
append wa_valuationextx to it_valuationextx.

"populate fields of struture and append to itab
append wa_warehousenumberdata to it_warehousenumberdata.

"populate fields of struture and append to itab
append wa_warehousenumberdatax to it_warehousenumberdatax.

"populate fields of struture and append to itab
append wa_warehousenumberext to it_warehousenumberext.

"populate fields of struture and append to itab
append wa_warehousenumberextx to it_warehousenumberextx.

"populate fields of struture and append to itab
append wa_storagetypedata to it_storagetypedata.

"populate fields of struture and append to itab
append wa_storagetypedatax to it_storagetypedatax.

"populate fields of struture and append to itab
append wa_storagetypeext to it_storagetypeext.

"populate fields of struture and append to itab
append wa_storagetypeextx to it_storagetypeextx.

"populate fields of struture and append to itab
append wa_salesdata to it_salesdata.

"populate fields of struture and append to itab
append wa_salesdatax to it_salesdatax.

"populate fields of struture and append to itab
append wa_salesext to it_salesext.

"populate fields of struture and append to itab
append wa_salesextx to it_salesextx.

"populate fields of struture and append to itab
append wa_posdata to it_posdata.

"populate fields of struture and append to itab
append wa_posdatax to it_posdatax.

"populate fields of struture and append to itab
append wa_posext to it_posext.

"populate fields of struture and append to itab
append wa_posextx to it_posextx.

"populate fields of struture and append to itab
append wa_materiallongtext to it_materiallongtext.

"populate fields of struture and append to itab
append wa_plantkeys to it_plantkeys.

"populate fields of struture and append to itab
append wa_storagelocationkeys to it_storagelocationkeys.

"populate fields of struture and append to itab
append wa_distrchainkeys to it_distrchainkeys.

"populate fields of struture and append to itab
append wa_warehousenokeys to it_warehousenokeys.

"populate fields of struture and append to itab
append wa_storagetypekeys to it_storagetypekeys.

"populate fields of struture and append to itab
append wa_valuationtypekeys to it_valuationtypekeys.

"populate fields of struture and append to itab
append wa_textilecomponents to it_textilecomponents.

"populate fields of struture and append to itab
append wa_fibercodes to it_fibercodes.

"populate fields of struture and append to itab
append wa_receivers to it_receivers.

"populate fields of struture and append to itab
append wa_communication_documents to it_communication_documents.

"populate fields of struture and append to itab
append wa_application_objects to it_application_objects. . CALL FUNCTION 'ALE_MATERIAL_MAINTAINDATA_RT' EXPORTING headdata = ld_headdata * obj_type = ld_obj_type * serial_id = ld_serial_id TABLES * variantskeys = it_variantskeys * characteristicvalue = it_characteristicvalue * characteristicvaluex = it_characteristicvaluex * clientdata = it_clientdata * clientdatax = it_clientdatax * clientext = it_clientext * clientextx = it_clientextx * addnlclientdata = it_addnlclientdata * addnlclientdatax = it_addnlclientdatax * materialdescription = it_materialdescription * plantdata = it_plantdata * plantdatax = it_plantdatax * plantext = it_plantext * plantextx = it_plantextx * forecastparameters = it_forecastparameters * forecastparametersx = it_forecastparametersx * forecastvalues = it_forecastvalues * totalconsumption = it_totalconsumption * unplndconsumption = it_unplndconsumption * planningdata = it_planningdata * planningdatax = it_planningdatax * storagelocationdata = it_storagelocationdata * storagelocationdatax = it_storagelocationdatax * storagelocationext = it_storagelocationext * storagelocationextx = it_storagelocationextx * unitsofmeasure = it_unitsofmeasure * unitsofmeasurex = it_unitsofmeasurex * unitofmeasuretexts = it_unitofmeasuretexts * internationalartnos = it_internationalartnos * vendorean = it_vendorean * layoutmoduleassgmt = it_layoutmoduleassgmt * layoutmoduleassgmtx = it_layoutmoduleassgmtx * taxclassifications = it_taxclassifications * valuationdata = it_valuationdata * valuationdatax = it_valuationdatax * valuationext = it_valuationext * valuationextx = it_valuationextx * warehousenumberdata = it_warehousenumberdata * warehousenumberdatax = it_warehousenumberdatax * warehousenumberext = it_warehousenumberext * warehousenumberextx = it_warehousenumberextx * storagetypedata = it_storagetypedata * storagetypedatax = it_storagetypedatax * storagetypeext = it_storagetypeext * storagetypeextx = it_storagetypeextx * salesdata = it_salesdata * salesdatax = it_salesdatax * salesext = it_salesext * salesextx = it_salesextx * posdata = it_posdata * posdatax = it_posdatax * posext = it_posext * posextx = it_posextx * materiallongtext = it_materiallongtext * plantkeys = it_plantkeys * storagelocationkeys = it_storagelocationkeys * distrchainkeys = it_distrchainkeys * warehousenokeys = it_warehousenokeys * storagetypekeys = it_storagetypekeys * valuationtypekeys = it_valuationtypekeys * textilecomponents = it_textilecomponents * fibercodes = it_fibercodes receivers = it_receivers * communication_documents = it_communication_documents * application_objects = it_application_objects EXCEPTIONS ERROR_CREATING_IDOCS = 1 . " ALE_MATERIAL_MAINTAINDATA_RT
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_headdata  TYPE BAPIE1MATHEAD ,
it_variantskeys  TYPE STANDARD TABLE OF BAPIE1VARKEY ,
wa_variantskeys  LIKE LINE OF it_variantskeys,
ld_obj_type  TYPE SERIAL-OBJ_TYPE ,
it_characteristicvalue  TYPE STANDARD TABLE OF BAPIE1AUSPRT ,
wa_characteristicvalue  LIKE LINE OF it_characteristicvalue,
ld_serial_id  TYPE SERIAL-CHNUM ,
it_characteristicvaluex  TYPE STANDARD TABLE OF BAPIE1AUSPRTX ,
wa_characteristicvaluex  LIKE LINE OF it_characteristicvaluex,
it_clientdata  TYPE STANDARD TABLE OF BAPIE1MARART ,
wa_clientdata  LIKE LINE OF it_clientdata,
it_clientdatax  TYPE STANDARD TABLE OF BAPIE1MARARTX ,
wa_clientdatax  LIKE LINE OF it_clientdatax,
it_clientext  TYPE STANDARD TABLE OF BAPIE1MARAEXTRT ,
wa_clientext  LIKE LINE OF it_clientext,
it_clientextx  TYPE STANDARD TABLE OF BAPIE1MARAEXTRTX ,
wa_clientextx  LIKE LINE OF it_clientextx,
it_addnlclientdata  TYPE STANDARD TABLE OF BAPIE1MAW1RT ,
wa_addnlclientdata  LIKE LINE OF it_addnlclientdata,
it_addnlclientdatax  TYPE STANDARD TABLE OF BAPIE1MAW1RTX ,
wa_addnlclientdatax  LIKE LINE OF it_addnlclientdatax,
it_materialdescription  TYPE STANDARD TABLE OF BAPIE1MAKTRT ,
wa_materialdescription  LIKE LINE OF it_materialdescription,
it_plantdata  TYPE STANDARD TABLE OF BAPIE1MARCRT ,
wa_plantdata  LIKE LINE OF it_plantdata,
it_plantdatax  TYPE STANDARD TABLE OF BAPIE1MARCRTX ,
wa_plantdatax  LIKE LINE OF it_plantdatax,
it_plantext  TYPE STANDARD TABLE OF BAPIE1MARCEXTRT ,
wa_plantext  LIKE LINE OF it_plantext,
it_plantextx  TYPE STANDARD TABLE OF BAPIE1MARCEXTRTX ,
wa_plantextx  LIKE LINE OF it_plantextx,
it_forecastparameters  TYPE STANDARD TABLE OF BAPIE1MPOPRT ,
wa_forecastparameters  LIKE LINE OF it_forecastparameters,
it_forecastparametersx  TYPE STANDARD TABLE OF BAPIE1MPOPRTX ,
wa_forecastparametersx  LIKE LINE OF it_forecastparametersx,
it_forecastvalues  TYPE STANDARD TABLE OF BAPIE1MPRWRT ,
wa_forecastvalues  LIKE LINE OF it_forecastvalues,
it_totalconsumption  TYPE STANDARD TABLE OF BAPIE1MVEGRT ,
wa_totalconsumption  LIKE LINE OF it_totalconsumption,
it_unplndconsumption  TYPE STANDARD TABLE OF BAPIE1MVEURT ,
wa_unplndconsumption  LIKE LINE OF it_unplndconsumption,
it_planningdata  TYPE STANDARD TABLE OF BAPIE1MPGDRT ,
wa_planningdata  LIKE LINE OF it_planningdata,
it_planningdatax  TYPE STANDARD TABLE OF BAPIE1MPGDRTX ,
wa_planningdatax  LIKE LINE OF it_planningdatax,
it_storagelocationdata  TYPE STANDARD TABLE OF BAPIE1MARDRT ,
wa_storagelocationdata  LIKE LINE OF it_storagelocationdata,
it_storagelocationdatax  TYPE STANDARD TABLE OF BAPIE1MARDRTX ,
wa_storagelocationdatax  LIKE LINE OF it_storagelocationdatax,
it_storagelocationext  TYPE STANDARD TABLE OF BAPIE1MARDEXTRT ,
wa_storagelocationext  LIKE LINE OF it_storagelocationext,
it_storagelocationextx  TYPE STANDARD TABLE OF BAPIE1MARDEXTRTX ,
wa_storagelocationextx  LIKE LINE OF it_storagelocationextx,
it_unitsofmeasure  TYPE STANDARD TABLE OF BAPIE1MARMRT ,
wa_unitsofmeasure  LIKE LINE OF it_unitsofmeasure,
it_unitsofmeasurex  TYPE STANDARD TABLE OF BAPIE1MARMRTX ,
wa_unitsofmeasurex  LIKE LINE OF it_unitsofmeasurex,
it_unitofmeasuretexts  TYPE STANDARD TABLE OF BAPIE1MAMTRT ,
wa_unitofmeasuretexts  LIKE LINE OF it_unitofmeasuretexts,
it_internationalartnos  TYPE STANDARD TABLE OF BAPIE1MEANRT ,
wa_internationalartnos  LIKE LINE OF it_internationalartnos,
it_vendorean  TYPE STANDARD TABLE OF BAPIE1MLEART ,
wa_vendorean  LIKE LINE OF it_vendorean,
it_layoutmoduleassgmt  TYPE STANDARD TABLE OF BAPIE1MALGRT ,
wa_layoutmoduleassgmt  LIKE LINE OF it_layoutmoduleassgmt,
it_layoutmoduleassgmtx  TYPE STANDARD TABLE OF BAPIE1MALGRTX ,
wa_layoutmoduleassgmtx  LIKE LINE OF it_layoutmoduleassgmtx,
it_taxclassifications  TYPE STANDARD TABLE OF BAPIE1MLANRT ,
wa_taxclassifications  LIKE LINE OF it_taxclassifications,
it_valuationdata  TYPE STANDARD TABLE OF BAPIE1MBEWRT ,
wa_valuationdata  LIKE LINE OF it_valuationdata,
it_valuationdatax  TYPE STANDARD TABLE OF BAPIE1MBEWRTX ,
wa_valuationdatax  LIKE LINE OF it_valuationdatax,
it_valuationext  TYPE STANDARD TABLE OF BAPIE1MBEWEXTRT ,
wa_valuationext  LIKE LINE OF it_valuationext,
it_valuationextx  TYPE STANDARD TABLE OF BAPIE1MBEWEXTRTX ,
wa_valuationextx  LIKE LINE OF it_valuationextx,
it_warehousenumberdata  TYPE STANDARD TABLE OF BAPIE1MLGNRT ,
wa_warehousenumberdata  LIKE LINE OF it_warehousenumberdata,
it_warehousenumberdatax  TYPE STANDARD TABLE OF BAPIE1MLGNRTX ,
wa_warehousenumberdatax  LIKE LINE OF it_warehousenumberdatax,
it_warehousenumberext  TYPE STANDARD TABLE OF BAPIE1MLGNEXTRT ,
wa_warehousenumberext  LIKE LINE OF it_warehousenumberext,
it_warehousenumberextx  TYPE STANDARD TABLE OF BAPIE1MLGNEXTRTX ,
wa_warehousenumberextx  LIKE LINE OF it_warehousenumberextx,
it_storagetypedata  TYPE STANDARD TABLE OF BAPIE1MLGTRT ,
wa_storagetypedata  LIKE LINE OF it_storagetypedata,
it_storagetypedatax  TYPE STANDARD TABLE OF BAPIE1MLGTRTX ,
wa_storagetypedatax  LIKE LINE OF it_storagetypedatax,
it_storagetypeext  TYPE STANDARD TABLE OF BAPIE1MLGTEXTRT ,
wa_storagetypeext  LIKE LINE OF it_storagetypeext,
it_storagetypeextx  TYPE STANDARD TABLE OF BAPIE1MLGTEXTRTX ,
wa_storagetypeextx  LIKE LINE OF it_storagetypeextx,
it_salesdata  TYPE STANDARD TABLE OF BAPIE1MVKERT ,
wa_salesdata  LIKE LINE OF it_salesdata,
it_salesdatax  TYPE STANDARD TABLE OF BAPIE1MVKERTX ,
wa_salesdatax  LIKE LINE OF it_salesdatax,
it_salesext  TYPE STANDARD TABLE OF BAPIE1MVKEEXTRT ,
wa_salesext  LIKE LINE OF it_salesext,
it_salesextx  TYPE STANDARD TABLE OF BAPIE1MVKEEXTRTX ,
wa_salesextx  LIKE LINE OF it_salesextx,
it_posdata  TYPE STANDARD TABLE OF BAPIE1WLK2RT ,
wa_posdata  LIKE LINE OF it_posdata,
it_posdatax  TYPE STANDARD TABLE OF BAPIE1WLK2RTX ,
wa_posdatax  LIKE LINE OF it_posdatax,
it_posext  TYPE STANDARD TABLE OF BAPIE1WLK2EXTRT ,
wa_posext  LIKE LINE OF it_posext,
it_posextx  TYPE STANDARD TABLE OF BAPIE1WLK2EXTRTX ,
wa_posextx  LIKE LINE OF it_posextx,
it_materiallongtext  TYPE STANDARD TABLE OF BAPIE1MLTXRT ,
wa_materiallongtext  LIKE LINE OF it_materiallongtext,
it_plantkeys  TYPE STANDARD TABLE OF BAPIE1WRKKEY ,
wa_plantkeys  LIKE LINE OF it_plantkeys,
it_storagelocationkeys  TYPE STANDARD TABLE OF BAPIE1LGOKEY ,
wa_storagelocationkeys  LIKE LINE OF it_storagelocationkeys,
it_distrchainkeys  TYPE STANDARD TABLE OF BAPIE1VTLKEY ,
wa_distrchainkeys  LIKE LINE OF it_distrchainkeys,
it_warehousenokeys  TYPE STANDARD TABLE OF BAPIE1LGNKEY ,
wa_warehousenokeys  LIKE LINE OF it_warehousenokeys,
it_storagetypekeys  TYPE STANDARD TABLE OF BAPIE1LGTKEY ,
wa_storagetypekeys  LIKE LINE OF it_storagetypekeys,
it_valuationtypekeys  TYPE STANDARD TABLE OF BAPIE1BWAKEY ,
wa_valuationtypekeys  LIKE LINE OF it_valuationtypekeys,
it_textilecomponents  TYPE STANDARD TABLE OF BAPITEXTLCOMP ,
wa_textilecomponents  LIKE LINE OF it_textilecomponents,
it_fibercodes  TYPE STANDARD TABLE OF BAPITEXTLFIBR ,
wa_fibercodes  LIKE LINE OF it_fibercodes,
it_receivers  TYPE STANDARD TABLE OF BDI_LOGSYS ,
wa_receivers  LIKE LINE OF it_receivers,
it_communication_documents  TYPE STANDARD TABLE OF SWOTOBJID ,
wa_communication_documents  LIKE LINE OF it_communication_documents,
it_application_objects  TYPE STANDARD TABLE OF SWOTOBJID ,
wa_application_objects  LIKE LINE OF it_application_objects.

ld_headdata = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_variantskeys to it_variantskeys.

ld_obj_type = some text here

"populate fields of struture and append to itab
append wa_characteristicvalue to it_characteristicvalue.

ld_serial_id = Check type of data required

"populate fields of struture and append to itab
append wa_characteristicvaluex to it_characteristicvaluex.

"populate fields of struture and append to itab
append wa_clientdata to it_clientdata.

"populate fields of struture and append to itab
append wa_clientdatax to it_clientdatax.

"populate fields of struture and append to itab
append wa_clientext to it_clientext.

"populate fields of struture and append to itab
append wa_clientextx to it_clientextx.

"populate fields of struture and append to itab
append wa_addnlclientdata to it_addnlclientdata.

"populate fields of struture and append to itab
append wa_addnlclientdatax to it_addnlclientdatax.

"populate fields of struture and append to itab
append wa_materialdescription to it_materialdescription.

"populate fields of struture and append to itab
append wa_plantdata to it_plantdata.

"populate fields of struture and append to itab
append wa_plantdatax to it_plantdatax.

"populate fields of struture and append to itab
append wa_plantext to it_plantext.

"populate fields of struture and append to itab
append wa_plantextx to it_plantextx.

"populate fields of struture and append to itab
append wa_forecastparameters to it_forecastparameters.

"populate fields of struture and append to itab
append wa_forecastparametersx to it_forecastparametersx.

"populate fields of struture and append to itab
append wa_forecastvalues to it_forecastvalues.

"populate fields of struture and append to itab
append wa_totalconsumption to it_totalconsumption.

"populate fields of struture and append to itab
append wa_unplndconsumption to it_unplndconsumption.

"populate fields of struture and append to itab
append wa_planningdata to it_planningdata.

"populate fields of struture and append to itab
append wa_planningdatax to it_planningdatax.

"populate fields of struture and append to itab
append wa_storagelocationdata to it_storagelocationdata.

"populate fields of struture and append to itab
append wa_storagelocationdatax to it_storagelocationdatax.

"populate fields of struture and append to itab
append wa_storagelocationext to it_storagelocationext.

"populate fields of struture and append to itab
append wa_storagelocationextx to it_storagelocationextx.

"populate fields of struture and append to itab
append wa_unitsofmeasure to it_unitsofmeasure.

"populate fields of struture and append to itab
append wa_unitsofmeasurex to it_unitsofmeasurex.

"populate fields of struture and append to itab
append wa_unitofmeasuretexts to it_unitofmeasuretexts.

"populate fields of struture and append to itab
append wa_internationalartnos to it_internationalartnos.

"populate fields of struture and append to itab
append wa_vendorean to it_vendorean.

"populate fields of struture and append to itab
append wa_layoutmoduleassgmt to it_layoutmoduleassgmt.

"populate fields of struture and append to itab
append wa_layoutmoduleassgmtx to it_layoutmoduleassgmtx.

"populate fields of struture and append to itab
append wa_taxclassifications to it_taxclassifications.

"populate fields of struture and append to itab
append wa_valuationdata to it_valuationdata.

"populate fields of struture and append to itab
append wa_valuationdatax to it_valuationdatax.

"populate fields of struture and append to itab
append wa_valuationext to it_valuationext.

"populate fields of struture and append to itab
append wa_valuationextx to it_valuationextx.

"populate fields of struture and append to itab
append wa_warehousenumberdata to it_warehousenumberdata.

"populate fields of struture and append to itab
append wa_warehousenumberdatax to it_warehousenumberdatax.

"populate fields of struture and append to itab
append wa_warehousenumberext to it_warehousenumberext.

"populate fields of struture and append to itab
append wa_warehousenumberextx to it_warehousenumberextx.

"populate fields of struture and append to itab
append wa_storagetypedata to it_storagetypedata.

"populate fields of struture and append to itab
append wa_storagetypedatax to it_storagetypedatax.

"populate fields of struture and append to itab
append wa_storagetypeext to it_storagetypeext.

"populate fields of struture and append to itab
append wa_storagetypeextx to it_storagetypeextx.

"populate fields of struture and append to itab
append wa_salesdata to it_salesdata.

"populate fields of struture and append to itab
append wa_salesdatax to it_salesdatax.

"populate fields of struture and append to itab
append wa_salesext to it_salesext.

"populate fields of struture and append to itab
append wa_salesextx to it_salesextx.

"populate fields of struture and append to itab
append wa_posdata to it_posdata.

"populate fields of struture and append to itab
append wa_posdatax to it_posdatax.

"populate fields of struture and append to itab
append wa_posext to it_posext.

"populate fields of struture and append to itab
append wa_posextx to it_posextx.

"populate fields of struture and append to itab
append wa_materiallongtext to it_materiallongtext.

"populate fields of struture and append to itab
append wa_plantkeys to it_plantkeys.

"populate fields of struture and append to itab
append wa_storagelocationkeys to it_storagelocationkeys.

"populate fields of struture and append to itab
append wa_distrchainkeys to it_distrchainkeys.

"populate fields of struture and append to itab
append wa_warehousenokeys to it_warehousenokeys.

"populate fields of struture and append to itab
append wa_storagetypekeys to it_storagetypekeys.

"populate fields of struture and append to itab
append wa_valuationtypekeys to it_valuationtypekeys.

"populate fields of struture and append to itab
append wa_textilecomponents to it_textilecomponents.

"populate fields of struture and append to itab
append wa_fibercodes to it_fibercodes.

"populate fields of struture and append to itab
append wa_receivers to it_receivers.

"populate fields of struture and append to itab
append wa_communication_documents to it_communication_documents.

"populate fields of struture and append to itab
append wa_application_objects to it_application_objects.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name ALE_MATERIAL_MAINTAINDATA_RT or its description.