Fonction SAP BAPI_SERVICE_CREATE - Creation of a Service Master Record

Paramètre Reférence Type Long. Valeur par déf. Facultatif Description
IM_SERVICE_DATA BAPISRV_ASMD u 324 General Data for Service, Import
IM_SERVICE_DATAX BAPISRV_ASMDX u 49 Change Parameter for Service Data, Import
NO_NUMBER_RANGE_CHECK BAPIFLAG-BAPIFLAG C 1 X Indicator to Circumvent the Number Range Check
TESTRUN BAPIFLAG-BAPIFLAG C 1 X Switch to Simulation Mode for Write BAPIs

Paramètre Reférence Type Long. Description
EX_SERVICE_DATA BAPISRV_ASMD u 324 General Data for Service, Export
EX_SERVICE_DATAX BAPISRV_ASMDX u 49 Change Parameter for Service Data, Export
SERVICE BAPISRV_ASMD-SERVICE C 18 Service Number

Paramètre Reférence Long. Facultatif Description
EXTENSION_IN BAPIPAREX 990 X Reference Structure for BAPI Parameters EXTENSIONIN/EXTENSIONOUT
EXTENSION_OUT BAPIPAREX 990 X Reference Structure for BAPI Parameters EXTENSIONIN/EXTENSIONOUT
RETURN BAPIRET2 548 X Return Parameter(s)
SERVICE_DESCRIPTION BAPISRV_ASMDT 44 X Communication Structure Short Text: Service Master
SERVICE_LONG_TEXTS BAPISRV_TEXT 138 X Communication Structure Long Text: Service Master

Functionality
This Business Application Programming Interface (BAPI) is used in thecomponent External Services Management (MM-SRV).
The BAPI enables you to create service master records.

Notes
Authorization
To be able to create service master records, you need the relevantauthorization.
Authorization object Service Master (M_SRV_LS) is checkedfor activity 01 (Create).
Transfer

  • The service master data is transferred in the parameter
  • IM_SERVICE_DATA.
    • The change parameters are transferred in the parameter
    • IM_SERVICE_DATAX.
      • The short texts are transferred in the table SERVICE_DESCRIPTION

      • .
        • The long texts are transferred in the table SERVICE_LONG_TEXTS.

        • Return messages
          In addition to customers' own messages, success and error messages arereturned during the entire service master processing in the parameterRETURN. The RETURN table thus contains information as to whetherinterface data has been processed incorrectly and issues success orerror messages during the creation of service master records.
          Restrictions
          With this BAPI, it is not possible to:
          • Create several service master records at once. If you want to create
          • several service records, reinvoke the method prior to each creation of afurther master record.
            • Create a new service master record on the basis of an already existing
            • one using the Create with Reference function.
              • Specify the displayable fields in the service master via field selection
              • in Customizing. The field selection is not taken into account.
                • Create data for classification (configuration).

                • Customer enhancements
                  The following BAdIs are available for the BAPI BAPI_SERVICE_CREATE:
                  • Service Master: Modification of BAPI
                  • Interfaces (MMSRV_SM_BAPI_CUST)
                    • Enhancement of Service Master (MMSRV_SM_MAIN)

                    • Create Notification/Change Service Master
                    • (MMSRV_SM_NOTIFY)

                      Further information

                      Description
                      The BAPI returns the data of the service master record (except for theshort and long texts) via this structure.

                      Description
                      The BAPI returns the change parameters of the service master record viathis structure.

                      Description
                      Number of the service master record that was created with the BAPI.

                      Description
                      This structure contains all the data of a service master record (such asservice category, base unit of measure, etc.) except the short and longtexts.
                      Information on the meaning of the individual parameter fields isavailable in the relevant data element documentation in the ABAPDictionary.

                      Description
                      The value of the field determines whether the value from the interfaceor a default value (e.g. from the standard service catalog) is used forthe corresponding field in the structure IM_SERVICE_DATA.
                      If an 'X' has been set, the value from the interface is used.

                      Value range
                      'X',, =,,Value from the interface is used
                      Space,, =,,Value from the database is used

                      Default
                      Space

                      Description
                      Indicator showing whether a number range check is to be carried out.

                      Value range
                      'X',,= Number range check will not be carried out
                      Space = Number range check will be carried out

                      Default
                      SPACE

                      Description
                      The parameter serves as a test switch.
                      If the switch is set, the document is not saved.

                      Value range
                      Space = Document is to be saved
                      X ,,= Document is not to be saved

                      Default
                      SPACE

                      Description
                      This table enables you to extend the import parameters of the BAPIwithout modification.

                      Description
                      This table enables you to extend the export parameters of the BAPIwithout modification.

                      Description
                      The table contains all the messages issued during the processing.

                      Description
                      This table contains all the short texts for the service master record tobe created.
                      Short texts may consist of just one line and must be specified with thelanguage and the change indicator (I, U, D).
                      At least one short text must be created in the original language.

                      Description
                      This table contains all the long texts for the service master record tobe created.
                      Each line must be specified with a language and the change indicator.The change indicator of the first line applies to the entire long text.