SAP Function BAPI_BILLDOC_CREATEMULTIPLE - BAPI for Billing document Create

Parameter Reference Type Length Default Optional Text
CFCVALIDATION BAPI_AUX_INV-CFCVALIDATION C 1 SPACE X Run Plausibility Checks
TESTRUN BAPI_AUX_INV-TESTRUN C 1 SPACE X Activate Simulation Mode

Parameter Reference Length Optional Text
ADDITEMS BAPI_EXTDOC_A 50 X Additional Items (External Billing Doc.)
BAPI_BILLDOCNUMBER BAPI_FKKINV_BILLDOCNUMBER 44 X External or Internal Billing Doc. Number
EXTENSIONIN BAPIPAREX 990 X ExtensionIn
EXTENSIONOUT BAPIPAREX 990 X ExtensionOut
HEADERS BAPI_EXTDOC_H 157 Header (External Billing Doc.)
ITEMS BAPI_EXTDOC_I 273 X Items (External Billing Doc.)
RETURN BAPIRET2 548 Returns
TAXITEMS BAPI_EXTDOC_T 98 X Tax Items (External Billing Doc.)

Functionality
You can use this method to transfer billing documents from an externalsystem and recreate the billing documents in the Generic ContractAccounts Receivable and Payable (FI-CAX) system. The system copiesverbatim the amounts and quantities present in the billing documentsbelonging to the external system. The system converts all otherattributes present in the billing documents to the SAP standard.
After the transfer is complete, the system saves the billing documentsin the following tables:

  • DFKKINVBILL_H

  • DFKKINVBILL_I

  • DFKKINVBILL_T

  • DFKKINVBILL_A

  • Next, the system creates an invoicing order for all billing documentsthat are not simulated and then invoices the billing documents inFI-CAX.
    To ensure high performance, create several billing documents with eachmethod call.
    Enhancement
    You can enhance this BAPI by implementing the following BaDIs withoutany modification:
    • INV_BAPIBILL

    • FKKINV_BAPIBILL

    • Authorization check
      The BAPI does not carry out any individual authorization checks.
      Error check
      • The system checks all transferred data for errors. Each error is logged
      • in the export table RETURN.
        • The BAPI does not carry out any database changes and does
        • not create any billing documents if one or more errors are found.
          • If the checks are successfully completed, the system creates billing
          • documents and carries out database changes directly without the Updatetask.
            • The system executes the COMMIT-WORK command at the end of processing.

            • Errors are typically not generated during database changes. In case of a
            • mismatch between the number range of billing documents present in thesystem and those recreated in the system, the system terminatesprocessing and implicitly executes the ROLLBACK command.

              Description
              If the import parameter TESTRUN is selected, the BAPI does not performany database changes. However, all checks are carried out. Any errorsthat occur are saved in the export table RETURN.

              Description
              Contains optional items of the external billing documents.

              Description
              Contains the document numbers of the newly-created billing documents.

              Description
              You can provide the BAPI with additional data by using the import tableEXTENSIONIN. The BAPI does not directly use the table; instead, itforwards the table to the methods of the Business Add-In (BAdI)INV_BILL_CANCEL.

              Description
              The BAPI returns additional data to the calling function by using theexport table EXTENSIONOUT. The BAPI does not directly use the exporttable. If you want to make entries to the table, you must implement themethods of the Business Add-In (BAdI) INV_BILL_CANCEL.

              Description
              Contains the data of external billing document headers.

              Description
              Contains the data of external billing document items.

              Description
              The export table RETURN contains all error log messages. The presence ofone or more messages of type E ("Error") or A ("Abort") in the tableindicates that an error occurred that terminated processing.

              Description
              Contains the data of external billing document tax items. The table isrequired only if an external tax determination is desired.