SAP Function BAPI_SALESORDER_GETDETAILBOS - Sales Order with BOS: Display Order Data

Parameter Reference Type Length Default Optional Text
INTERNALUSE BAPIFLAG-BAPIFLAG C 1 SPACE X Checkbox Field - Internal Line
SALESDOCUMENT BAPIVBELN-VBELN C 10 Sales and Distribution Document Number

Parameter Reference Type Length Text
ORDERHEADER BAPISDHD u 817 Document Header Data

Parameter Reference Length Optional Text
EXTENSIONOUT BAPIPAREX 990 X Customer enhancements for export
ORDERADDRESS BAPISDCOAD 629 X Address Data
ORDERBILLINGDATES BAPISDBPLD 424 X Billing Data
ORDERBILLINGPLANS BAPISDBPL 166 X Billing plan
ORDERBUSINESS BAPISDBUSI 672 X Business Data
ORDERCFGSCUBLBS BAPICUBLBM 269 X Configuration BLOB
ORDERCFGSCUCFGS BAPICUCFGM 410 X Configuration Data
ORDERCFGSCUINS BAPICUINSM 246 X Instance Data for Configuration
ORDERCFGSCUPRTS BAPICUPRTM 136 X Detail Data (Part_of Entries) for Configuration
ORDERCFGSCUREFS BAPICUREFM 33 X Instance in Configuration
ORDERCFGSCUVALS BAPICUVALM 289 X Characteristic Values for Configuration
ORDERCFGSCUVKS BAPICUVKM 68 X Variant Condition Key in Configuration
ORDERCONDHEAD BAPICONDHD 376 X Conditions Header Data
ORDERCONDITEM BAPICONDIT 518 X Conditions Item Data
ORDERCONDITIONS BAPISDCOND 464 X Conditions
ORDERCONDQTYSCALE BAPICONDQS 72 X Condition Scale Quantity
ORDERCONDVALSCALE BAPICONDVS 81 X Condition Scale Value
ORDERCONTRACTS BAPISDCNTR 158 X Contract Data
ORDERCREDITCARDS BAPICCARDM 317 X Credit Card Data
ORDERFLOWS BAPISDFLOW 328 X Document Flow
ORDERITEMS BAPISDITBOS 1784 X Item Data
ORDERPARTNERS BAPISDPART 180 X Partner Data
ORDERSCHEDULELINES BAPISDHEDU 344 X Schedule Lines
ORDERSERVICES BAPISDESLLBOS 648 X Services
ORDERSERVICESCOND BAPIBOSCD 296 X Service Conditions
ORDERSERVICESCOST BAPIBOSCOST 444 X Communication Fields: Sales Document Item With BOS & Costing
ORDERSERVICESTEXT BAPIESLLTX 158 X Service Texts
ORDERSTATUSHEADERS BAPISDHDST 97 X Header Status
ORDERSTATUSITEMS BAPISDITST 55 X Item Status
ORDERTEXTHEADERS BAPISDTEHD 385 X Text Header Info.
ORDERTEXTLINES BAPITEXTLI 232 X Text Lines for Document
RETURN BAPIRET2 548 X Return Messages

Functionality
You can use this method to read detail data for a sales order with BOSand return this data to the calling program.

Notes
Transfer the SD document number as selection criterion to importparameter SalesDocument. A sales order is identified by thisserach criterion.
You can use parameter InternalUse to determine whether servicelines of line type internal line are also displayed.
Return values
The data for the selected sales order are returned in the followingtables:

  • Order header data via table OrderHeader

  • Partner data via table OrderPartners

  • Schedule line data via table OrderScheduleLines

  • Item data via table OrderItems

  • If you are dealing with configurable document items, the configurationdata is transferred from the following tables:
    • OrderCfgsRef

    • OrderCfgsInst

    • OrderCfgsPartOf

    • OrderCfgsValue

    • If you are dealing with document items with BOS, the service data istransferred from the following tables:
      • Service data via table OrderServices

      • Service long texts via table OrderServicesText

      • Service conditions via table OrderServicesCond

      • Customer fields - tables VBAK, VBAP, VBEP andESLL can be read via parameter ExtensionOut.
        Error handling
        If errors occur during processing, they are returned in table parameterReturn. Information messages are also logged in this parameter.

        Description
        This parameter contains the sales document header data.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.

        Description
        Indicator specifying that service lines of line type internal line are read by the system.

        Value range
        SPACE,,no long texts are displayed.
        X,,long texts are displayed.

        Default
        SPACE

        Description
        The SD document number serves to identify a sales order.

        Value range
        Dictionary data type CHAR (field length 10).

        Default
        This parameter must be entered (required field).
        INCLUDE BOS_BAPI_EXTENSIONOUT OBJECT DOKU ID TX

        Description
        This parameter contains the document address data.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.

        Description
        This parameter contains the billing data.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.

        Description
        Tis parameter contains the billing plan data.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.

        Description
        This parameter contains the business data for the order.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.
        INCLUDE BOS_BAPI_KONFIGURATION OBJECT DOKU ID TX
        INCLUDE BOS_BAPI_KONFIGURATION OBJECT DOKU ID TX
        INCLUDE BOS_BAPI_KONFIGURATION OBJECT DOKU ID TX
        INCLUDE BOS_BAPI_KONFIGURATION OBJECT DOKU ID TX
        INCLUDE BOS_BAPI_KONFIGURATION OBJECT DOKU ID TX
        INCLUDE BOS_BAPI_KONFIGURATION OBJECT DOKU ID TX
        INCLUDE BOS_BAPI_KONFIGURATION OBJECT DOKU ID TX

        Description
        This parameter contains the condition data for the document header.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.

        Description
        This parameter contains the condition data for the document items.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.

        Description
        This parameter contains the condition data for the document.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.

        Description
        This parameter contains condition data for the condition scalequantity.
        You can find further information on the meaning of the individualparameter fields in the appropraite data element documentation in theABAP dictionary.

        Description
        This parameter contains condition data for the condition scale value.
        You can find further information on the meaning of the individualparameter fields in the appropraite data element documentation in theABAP dictionary.

        Description
        This parameter contains the contract data.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.
        INCLUDE BOS_BAPI_KREDITKARTENDATEN OBJECT DOKU ID TX

        Description
        This parameter contains information on the document flow.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.

        Description
        This parameter contains the item data for the sales document.
        You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.
        INCLUDE BOS_BAPI_PARTNERDATEN OBJECT DOKU ID TX
        INCLUDE BOS_BAPI_EINTEILUNGSZEILEN OBJECT DOKU ID TX

        Description
        The transfer parameter contains the service lines and the outlinelevels in the bills of services for the order.

        Description
        This parameter contains condition data for the service lines andoutline levels.
        Each service line and outline level is identified by the package numberPCKG_NO and the internal line number LINE_NO.
        Each condition record for a service line or outline level is identifiedby the following fields (key):
        ITM_NUMBER,,order item
        PCKG_NO,,package number
        LINE_NO,,internal line number
        COND_ST_NO,,condition level
        COND_COUNT,,counter in the condition level

        Description
        This parameter contains cost item for the service liness.
        Each service line or outline level is identified by the package numberPCKG_NO and the internal line number LINE_NO .
        Each cost item for a service line or outline level can be identified bythe following fields (key):

        • ITM_NUMBER Quotation Item

        • PCKG_NO Package number

        • LINE_NO Internal Line number

        • ITEM_NUMBER Cost item number
        • Description
          The long texts for the service lines and outline levels are transferredin this parameter.

          Value range
          For field TEXT_ID:
          LTXT,,line long text / outline long text
          LLTX,,service long text

          Description
          This parameter contains status information for the selected document.
          You can find information on the meaning of the individual parameterfields in the appropriate data element documentation in the ABAPdictionary.

          Description
          This parameter contains status information on the document items in theselected document.
          You can find further information on the meaning of the individualparameter fields in the appropraite data element documentation in theABAP dictionary.

          Description
          If errors occur during processing, they are returned in the tableparameter Return. Information messages are also logged in thistable parameter.

          Value range
          If no error occurs, the return parameter is initial. Otherwise theappropriate error messages with short text are displayed.