SAP Function BAPI_INCOMINGINVOICE_PARK - Invoice Verification: Park Invoice

Parameter Reference Type Length Default Optional Text
ADDRESSDATA BAPI_INCINV_CREATE_ADDRESSDATA u 516 X Transfer Structure: Address Data Incoming Invoice (Create)
HEADERDATA BAPI_INCINV_CREATE_HEADER u 489 Transfer Structure for Invoice Header Data (Create)

Parameter Reference Type Length Text
FISCALYEAR BAPI_INCINV_FLD-FISC_YEAR N 4 Fiscal Year
INVOICEDOCNUMBER BAPI_INCINV_FLD-INV_DOC_NO C 10 Document Number of an Invoice Document

Parameter Reference Length Optional Text
ACCOUNTINGDATA BAPI_INCINV_CREATE_ACCOUNT 330 X Transfer Structure for Invoice Acct Assignment Data (Create)
EXTENSIONIN BAPIPAREX 990 X Enhancement Fields (Import Parameter)
GLACCOUNTDATA BAPI_INCINV_CREATE_GL_ACCOUNT 404 X Transfer Struct.: G/L Acct Posting Incoming Invoice (Create)
ITEMDATA BAPI_INCINV_CREATE_ITEM 216 Transfer Structure for Invoice Item Data (Create)
MATERIALDATA BAPI_INCINV_CREATE_MATERIAL 163 X Transfer Struct.: Material Posting Incoming Invoice (Create)
RETURN BAPIRET2 548 Return Parameter
TAXDATA BAPI_INCINV_CREATE_TAX 66 X Transfer Structure for Tax Data (Create)
VENDORITEMSPLITDATA BAPI_INCINV_CREATE_VENDORSPLIT 27 X Transfer Structure: Vendor Split Incoming Invoice (Create)
WITHTAXDATA BAPI_INCINV_CREATE_WITHTAX 46 X Transfer Structure: Withholding Tax Data (Create)

&FUNCTIONALITY&
You can use this method to parkincoming invoices.
When header data is transferred, you use the field INVOICE_IND todetermine whether the system generates a credit memo or an invoice. Ifyou leave the field initial, the system generates a credit memo.If you enter X, the system generates an invoice.
You use this method if information on posting an invoice document ismissing in the invoice document. The balance can be a value other thanzero. As in the online transaction, the following updates take place:for example, informative PO history, advance tax return, index forchecks re duplicate invoices, open creditor items from parked documents,log of document changes.
You can use this method to:

  • Park invoices with multiple account assignment

  • Change and park invoice account assignments

  • Park invoices for blanket purchase orders (see also the documentation
  • for the function moduleBAPI_INCOMINGINVOICE_CREATE)
    • Park invoices for purchase orders with planned delivery costs

    • Park invoices with unplanned delivery costs

    • Park subsequent credits and debits

    • Use document types with external number assignment

    • Park invoices with withholding tax

    • Park invoices with several creditor lines and different methods and
    • terms of payment
      • Park invoices for purchase orders for external services

      • Park invoices with G/L account postings

      • Park invoices with material account postings

      • Park invoices for a one-time
      • vendor
        • Park invoices with a different payee

        • Restrictions
          You cannot post invoices for returns orders
          The following FI fields are not passed on:
          • ISR subscriber number (ISR = inpayment slip with reference number)

          • Bank details

          • Payment reference

          • Short key for house bank

          • Service indicator
          • Notes
            The following authorization object is checked with activity 77:

            • M_RECH_WRKPlant authorization for entering incoming
            • invoices
              Transfer
              You transfer the header data of the incoming invoice using the structureHeaderData.
              The tables ItemData and AccountingData contain the itemdata of the incoming invoice. The TaxData table contains the taxinformation for the incoming invoice.
              The GlAccountData table contains data for posting to G/Laccounts, and the MaterialData table contains data for posting tomaterial accounts.
              You can use the WithTaxData table to pass on withholding taxinformation.
              You can use the VendorItemSplitData table to distribute the grossamount among several creditor lines with different methods and terms ofpayment.
              Return
              The document number of the invoice document and the fiscal year arereturned as key fields of the incoming invoice.
              Return messages
              INCLUDE BAPI_RET OBJECT DOKU ID TX LANGUAGE EN

              Further information
              INCLUDE BAPI_INVENTUR_WEITERINF OBJECT DOKU ID TX LANGUAGE EN

              Example: Incoming Invoice
              This example shows which header data you can park in the tableHeaderData and which item data you can park in the table
              ItemData.
              Purchase order: 10 pc of material A @ 10 USD
              Goods receipt: 10 pc of material A
              For this purchase order, you receive an invoice referencing PO number4500007491, PO item 10, for a quantity of 10 pc of material A and anamount of 116 USD incl. 16% VAT. You enter the following data:
              HeaderData table

              • INVOICE_IND (invoice/credit memo): X

              • DOC_DATE (document date): 05.20.2000

              • PSTNG_DATE (posting date): 05.23.2000

              • COMP_CODE (company code): 1000

              • GROSS_AMOUNT (gross amount): 116.00

              • CURRENCY (currency key): USD

              • CALC_TAX_IND (calculate tax): X

              • ItemData table
                • INVOICE_DOC_ITEM (item of the invoice document): 00001

                • PO_NUMBER (PO number): 4500007491

                • PO_ITEM (PO item): 00010

                • TAX_CODE (tax code): VN

                • ITEM_AMOUNT (item amount): 100

                • QUANTITY (quantity): 10

                • PO_UNIT (unit of measure): PC

                • For more information, see the parameter documentation for the tablesHeaderData andItemData.

                  Example: Incoming invoice with foreign currency, GR-based invoiceverification, and tax information
                  This example shows which header data you enter in the tableHeaderData, which item data you enter in the table ItemData
                  , and which tax information you enter in the table TaxData inorder to be able to park an incoming invoice in a foreign currency.
                  Purchase order: 10 pc of material A @ 10 USD
                  Goods receipt 1: 4 pc of material A
                  Goods receipt 2: 6 pc of material A
                  For this purchase order, you receive an invoice referencing PO no.4500007505, PO item 10, goods receipt document 50010095, 2000, item 1. Aquantity of 4 pc of material A and a gross amount of 46.60 USD and 16%tax (6.60 USD) is invoiced. You enter the following data:
                  HeaderData table

                  • INVOICE_IND (invoice/credit memo): X

                  • DOC_DATE (document date): 05.20.2000

                  • PSTNG_DATE (posting date): 05.23.2000

                  • COMP_CODE (company code): 1000

                  • CURRENCY (currency key): USD

                  • GROSS_AMOUNT (gross amount): 46.60

                  • ItemData table
                    • INVOICE_DOC_ITEM (item of invoice document): 00001

                    • PO_NUMBER (PO number): 4500007505

                    • PO_ITEM (PO item): 00010

                    • REF_DOC (goods receipt document): 50010095

                    • REF_DOC_YEAR (fiscal year of current period): 2000

                    • REF_DOC_ITEM (item of GR document): 1

                    • TAX_CODE (tax code): VN

                    • ITEM_AMOUNT (item amount): 40.00

                    • QUANTITY (quantity): 4

                    • PO_UNIT (unit of measure): PC

                    • TaxData table
                      • TAX_CODE (tax code): VN

                      • TAX_AMOUNT (tax amount in document currency): 6.60

                      • For more information, see the parameter documentation for the tablesHeaderData,ItemData andTaxData.

                        Example: Change existing account assignments and add new ones
                        This example shows which header data you enter in the HeaderDatatable, which item data you enter in the ItemData table, and whichaccount assignment data you enter in the AccountingData table inorder to be able to change account assignments for an incoming invoice.For you to be able to change account assignments, a non-valuated goodsreceipt or no goods receipt must exist. GR-based invoice verificationtakes place.
                        Purchase order: 300 pc of material A @ 1.00 USD
                        Goods receipt: 300 pc of material A
                        For this PO with multiple account assignment, you receive an invoicereferencing to PO no. 4500006846, PO item 10, goods receipt document50008849, 2000, item 1. A quantity of 100 pc of material A and a grossamount of 116.00 USD incl. 16% VAT is invoiced. You wish to change theplanned account assignment for the second account assignment item andadd an unplanned account assignment. You enter the following data:
                        HeaderData table

                        • INVOICE_IND (invoice/credit memo): X

                        • DOC_DATE (document date): 08.05.2000

                        • PSTNG_DATE (posting date): 08.08.2000

                        • COMP_CODE (company code): 1000

                        • CURRENCY (currency key): USD

                        • GROSS_AMOUNT (gross amount): 17.40

                        • CALC_TAX_IND (calculate tax automatically): X

                        • PMNTTRMS (terms of payment key): 0001

                        • ItemData table
                          • INVOICE_DOC_ITEM (invoice document item): 00001

                          • PO_NUMBER (PO number): 4500006846

                          • PO_ITEM (PO item): 00010

                          • REF_DOC (goods receipt document): 500008849

                          • REF_DOC_YEAR (fiscal year of current period): 2000

                          • REF_DOC_ITEM (item of goods receipt document): 1

                          • TAX_CODE (tax code): VN

                          • ITEM_AMOUNT (item amount): 100

                          • QUANTITY (quantity): 100

                          • PO_UNIT (unit of measure): PC

                          • AccountingData table
                            Line 1: Change second account assignment item
                            • INVOICE_DOC_ITEM (Document item in invoice document): 0001

                            • SERIAL_NO (running number of account assignment): 02

                            • TAX_CODE (tax code): VN

                            • ITEM_AMOUNT (amount in document currency): 10.00

                            • QUANTITY (quantity): 10

                            • PO_UNIT (purchase order unit): PC

                            • GL_ACCOUNT (number of G/L account): 890000

                            • COSTCENTER (cost center): 1200

                            • Line 2: Add unplanned account assignment
                              • INVOICE_DOC_ITEM (document item in invoice document): 0001

                              • XUNPL (unplanned account assignment from invoice verification): X

                              • TAX_CODE (tax code): VN

                              • ITEM_AMOUNT (amount in document currency): 5.00

                              • QUANTITY (quantity): 5

                              • PO_UNIT (purchase order unit): PC

                              • GL_ACCOUNT (number of G/L account): 890000

                              • COSTCENTER (cost center): 1200

                              • For more information, see the parameter documentation for the tablesHeaderData,ItemData andAccountingData orthe Logistics Invoice Verification section of the SAP Library.

                                Example: Incoming invoice with planned delivery costs
                                This example shows which header data you enter in the HeaderDatatable, which item data you enter in the table ItemData table, andwhich tax information you enter in the TaxData table in order tobe able to generate an incoming invoice with planned delivery costs.
                                Purchase order: 100 pc of material A @ 1.00 USD
                                Goods receipt: 100 pc of material A
                                For this purchase order, you receive an invoice referencing PO no.4500006986, PO item 10, for a quantity of 100 pc of material A and anamount of 136.00 USD incl. 16% VAT and 20.00 USD planned delivery costs.You enter the following data:
                                HeaderData table

                                • INVOICE_IND (invoice/credit memo): X

                                • DOC_DATE (document date): 08.10.2000

                                • PSTNG_DATE (posting date): 08.12.2000

                                • COMP_CODE (company code): 1000

                                • CURRENCY (currency key): USD

                                • GROSS_AMOUNT (gross amount): 136.00

                                • ItemData table
                                  Line 1: Entry of PO item
                                  • INVOICE_DOC_ITEM (item of invoice document): 00001

                                  • PO_NUMBER (PO number): 4500006986

                                  • PO_ITEM (PO item): 00010

                                  • TAX_CODE (tax code): VN

                                  • ITEM_AMOUNT (item amount): 100.00

                                  • QUANTITY (quantity): 100

                                  • PO_UNIT (unit of measure): PC

                                  • Line 2: Entry of planned delivery costs
                                    • INVOICE_DOC_ITEM (item of invoice document): 00002

                                    • PO_NUMBER (PO number): 4500006986

                                    • PO_ITEM (PO item): 00010

                                    • ITEM_AMOUNT (item amount): 20.00

                                    • QUANTITY (quantity): 100

                                    • PO_UNIT (unit of measure): PC

                                    • COND_TYPE (condition type): FRB1

                                    • TaxData table
                                      • TAX_CODE (tax code): VN

                                      • TAX_AMOUNT (tax amount in document currency): 16.00

                                      • For more information, see the parameter documentation for the tablesHeaderData,ItemData andTaxData.

                                        Example: Incoming invoice with withholding tax
                                        This example shows which header data you enter in the HeaderDatatable, which item data you enter in the Itemdata table, and whichwithholding tax information you enter in the WithTaxData table inorder to be able to park an incoming invoice with withholding tax.
                                        Purchase order: 10 pc of material A @ 10.00 USD
                                        Goods receipt: 10 pc of material A
                                        For this purchase order, you receive an invoice referencing PO no.4500007505, PO item 10, goods receipt document 50010095, 2000, item 1. Aquantity of 10 pieces and a gross amount of 100.00 USD is invoiced. Forthe gross amount, you must pay 10% withholding tax. You enter thefollowing data:
                                        HeaderData table

                                        • INVOICE_IND (invoice/credit memo): X

                                        • DOC_DATE (document date): 05.20.2000

                                        • PSTNG_DATE (posting date): 05.23.2000

                                        • COMP_CODE (company code): WT01

                                        • CURRENCY (currency key): USD

                                        • GROSS_AMOUNT (gross amount): 100.00

                                        • ItemData table
                                          • INVOICE_DOC_ITEM (item of invoice document): 00001

                                          • PO_NUMBER (PO number): 4500007505

                                          • PO_ITEM (PO item): 00010

                                          • REF_DOC (goods receipt document): 50010095

                                          • REF_DOC_YEAR (fiscal year of the current period): 2000

                                          • REF_DOC_ITEM (item of a goods receipt document): 1

                                          • TAX_CODE (tax code): V0

                                          • ITEM_AMOUNT (item amount): 100.00

                                          • QUANTITY (quantity): 10.00

                                          • PO_UNIT (unit of measure): PC

                                          • WithTaxData table
                                            • SPLIT_KEY (grouping key for splitting withholding tax): 0001

                                            • WI_TAX_TYPE (indicator for withholding tax type): R1

                                            • WI_TAX_CODE (withholding tax code): 01

                                            • WI_TAX_BASE (withholding tax base amount): 100

                                            • WI_TAX_AMT (withholding tax amount in document currency): 10.00

                                            • For more information, see the parameter documentation for the tablesHeaderData,ItemData and
                                              WithTaxData.

                                              Example: Incoming invoice with amount split
                                              This example shows which header data you enter in the HeaderDatatable, which item data you enter in the Itemdata table, and whichinformation you enter in the VendorItemSplitData table in orderto generate an incoming invoice with an amount split.
                                              Purchase order: 10 pc of material A @ 10.00 USD
                                              Goods receipt: 10 pc of material A
                                              For this purchase order, you receive an invoice referencing PO no.4500007505, PO item 10, goods receipt document 50010095, 2000, item 1. Aquantity of 10 pc and a gross amount of 100.00 USD is invoiced. You wantto split the gross amount among two creditor lines. 40% of the grossamount is to be paid immediately by check and 60% of the gross amount isto be paid within 14 days, taking advantage of a 3% discount. You enterthe following data:
                                              HeaderData table

                                              • INVOICE_IND (invoice/credit memo): X

                                              • DOC_DATE (document date): 05.20.2000

                                              • PSTNG_DATE (posting date): 05.23.2000

                                              • COMP_CODE (company code): 0001

                                              • CURRENCY (currency key): USD

                                              • GROSS_AMOUNT (gross amount): 100.00

                                              • ItemData table
                                                • INVOICE_DOC_ITEM (item of invoice document): 00001

                                                • PO_NUMBER (PO number): 4500007505

                                                • PO_ITEM (PO item): 00010

                                                • REF_DOC (goods receipt document): 50010095

                                                • REF_DOC_YEAR (fiscal year of current period): 2000

                                                • REF_DOC_ITEM (item of a goods receipt document): 1

                                                • TAX_CODE (tax code): V0

                                                • ITEM_AMOUNT (item amount): 100.00

                                                • QUANTITY (quantity): 10.00

                                                • PO_UNIT (unit of measure): PC

                                                • VendorItemSplitData table
                                                  Creditor line 1
                                                  • SPLIT_KEY (grouping key for splitting creditor line): 0001

                                                  • SPLIT_AMOUNT(partial invoice amount in document currency): 40.00

                                                  • PYMT_METH (payment method): S

                                                  • TAX_CODE (tax code): V0

                                                  • PMNTTRMS (terms of payment key): 0001

                                                  • Creditr line 2
                                                    • SPLIT_KEY (grouping key for splitting creditor line): 0002

                                                    • SPLIT_AMOUNT (partial invoice amount in document currency): 60.00

                                                    • PYMT_METH (payment method): U

                                                    • TAX_CODE (tax code): V0

                                                    • PMNTTRMS (terms of payment key): 0003

                                                    • For more information, see the parameter documentation for the tablesHeaderData,ItemData andVendorItemSplitData.

                                                      Example: Incoming invoice with G/L and material account posting.
                                                      This example shows you which header data you must enter in theHeaderData table, which item data you enter in the
                                                      ItemData table, which G/L account information you enter in theGlAccountData table, and which material account information youenter in the MateralData table in order to park an incominginvoice.
                                                      You receive an invoice referencing to PO no. 4500006846, PO item 10. Theinvoice is for a quantity of 100 pc of material A, and a gross amount of150.80 USD including 16% VAT. This includes a G/L account posting of 10USD to account 400000 in company code 1, and a material account postingto material MAT01n for 20 USD. Enter the following data:
                                                      HeaderData table

                                                      • INVOICE_IND (Post invoice/credit memo): X

                                                      • DOC_DATE (Document date): 05.08.2000

                                                      • PSTNG_DATE (Posting date): 08.08.2000

                                                      • COMP_CODE (Company code): 1000

                                                      • CURRENCY (Currency key): USD

                                                      • GROSS_AMOUNT (Gross amount): 150.80

                                                      • CALC_TAX_IND (Automatically calculate tax): X

                                                      • PMNTTRMS (Terms of payment key): 0001

                                                      • ItemData table
                                                        • INVOICE_DOC_ITEM (Item in invoice document): 00001

                                                        • PO_NUMBER (PO number): 4500006846

                                                        • PO_ITEM (PO item): 00010

                                                        • TAX_CODE (Tax code): VN

                                                        • ITEM_AMOUNT (Item amount): 100

                                                        • QUANTITY (Quantity): 100

                                                        • PO_UNIT (Unit of measure): PC

                                                        • GlAccountData table
                                                          • INVOICE_DOC_ITEM (Document item in invoice document): 00001

                                                          • GL_ACCOUNT (G/L account): 400000

                                                          • ITEM_AMOUNT (Item amount): 10.00

                                                          • DB_CR_IND (Debit/credit indicator): S

                                                          • COMP_CODE (Company code): 0001

                                                          • TAX_CODE (Tax code): VN

                                                          • COSTCENTER (Cost center): 1

                                                          • MaterialData table
                                                            • INVOICE_DOC_ITEM (Document item in invoice document): 0001

                                                            • MATERIAL (Material): MAT01

                                                            • PLANT (Valuation area): 0001

                                                            • DB_CR_INP (Debit/credit indicator): S

                                                            • ITEM_AMOUNT (Item data): 10.00

                                                            • QUANTITY (MENGE_D): 1

                                                            • PO_UNIT (PO unit of measure): PC

                                                            • TAX_CODE (Tax code): VN

                                                            • For more information, see the parameter documentation for the tablesHeaderData,ItemData, GlAccountData andMaterialData

                                                              Example: Incoming invoice for a purchase order for external services andservie-based invoice verification
                                                              This example shows which header data you must enter in theHeaderData table, which item data you must enter in theItemData table, and which account assignment data you must enterin the AccountingData table in order to enter and post anincoming invoice.
                                                              You receive an invoice referencing PO no. 4500000191, PO item 10. Theinvoice is for two services A and B, each with a quantity of six serviceunits. Service A has a gross amount of 580 USD including 16% VAT.Service B has 812 USD including 16% VAT. 50% of service A was assignedto each of the cost centers 1000 and 2000. 50% of service B was assignedto each of the cost centers 1000 and 3000. The service acceptance isperformed jointly for both services with the service entry sheet number1000000022. The account assignments cannot be changed. Enter thefollowing data:
                                                              HeaderData table

                                                              • INVOICE_IND (Post invoice/credit memo): X

                                                              • DOC_TYPE (Document type): RE

                                                              • DOC_DATE (Document date): 10.01.2002

                                                              • PSTNG_DATE (Posting date): 10.01.2002

                                                              • COMP_CODE (Company code): 0001

                                                              • CURRENCY (Currency key): USD

                                                              • GROSS_AMOUNT (Gross amount): 1392.00

                                                              • CALC_TAX_IND (Calculate tax automatically): X

                                                              • PMNTTRMS (Terms of payment key): 0001

                                                              • ItemData table
                                                                First entry for service A:
                                                                • INVOICE_DOC_ITEM (Item in invoice document): 000001

                                                                • PO_NUMBER (PO number): 4500000191

                                                                • PO_ITEM (PO item): 00010

                                                                • TAX_CODE (Tax code): V1

                                                                • ITEM_AMOUNT (Item amount): 250.0

                                                                • QUANTITY (Quantity): 3

                                                                • PO_UNIT (Unit of measure): SU

                                                                • SHEET_NO (Entry sheet number): 1000000022

                                                                • SHEET_ITEM (Line number) : 10

                                                                • Second entry for service A:
                                                                  • INVOICE_DOC_ITEM (Item in invoice document): 000002

                                                                  • PO_NUMBER (PO number): 4500000191

                                                                  • PO_ITEM (PO item): 00010

                                                                  • TAX_CODE (Tax code): V1

                                                                  • ITEM_AMOUNT (Item amount): 250.00

                                                                  • QUANTITY (Quantity): 3

                                                                  • PO_UNIT (Unit of measure): SU

                                                                  • SHEET_NO (Entry sheet number): 1000000022

                                                                  • SHEET_ITEM (Line number) : 10

                                                                  • First entry for service B:
                                                                    • INVOICE_DOC_ITEM (Item in invoice document): 000003

                                                                    • PO_NUMBER (PO number): 4500000191

                                                                    • PO_ITEM (PO item): 00010

                                                                    • TAX_CODE (Tax code): V1

                                                                    • ITEM_AMOUNT (Item amount): 350.0

                                                                    • QUANTITY (Quantity): 3

                                                                    • PO_UNIT (Unit of measure): SU

                                                                    • SHEET_NO (Entry sheet number): 1000000022

                                                                    • SHEET_ITEM (Line number) : 20

                                                                    • Second entry for service B:
                                                                      • INVOICE_DOC_ITEM (Item in invoice document): 000004

                                                                      • PO_NUMBER (PO number): 4500000191

                                                                      • PO_ITEM (PO item): 00010

                                                                      • TAX_CODE (Tax code): V1

                                                                      • ITEM_AMOUNT (Item amount): 350.00

                                                                      • QUANTITY (Quantity): 3

                                                                      • PO_UNIT (Unit of measure): SU

                                                                      • SHEET_NO (Entry sheet number): 1000000022

                                                                      • SHEET_ITEM (Line number) : 20

                                                                      • AccountingData table
                                                                        First account assignment for service A:
                                                                        • INVOICE_DOC_ITEM (Document item in invoice document): 000001

                                                                        • SERIAL_NO (Sequential number of the account assignment): 01

                                                                        • TAX_CODE (Tax code): V1

                                                                        • ITEM_AMOUNT (Amount in document currency): 250.00

                                                                        • QUANTITY (Quantity): 3

                                                                        • PO_UNIT (PO unit of measure): SU

                                                                        • Second account assignment for service A:
                                                                          • INVOICE_DOC_ITEM (Document item in invoice document): 000002

                                                                          • SERIAL_NO (Running number of account assignment): 02

                                                                          • TAX_CODE (Tax code): V1

                                                                          • ITEM_AMOUNT (Amount in document currency): 250.00

                                                                          • QUANTITY (Quantity): 3

                                                                          • PO_UNIT (PO unit of measure): SU

                                                                          • First account assignment for service B:
                                                                            • INVOICE_DOC_ITEM (Document item in invoice document): 000003

                                                                            • SERIAL_NO (Running number of account assignment): 01

                                                                            • TAX_CODE (Tax code): V1

                                                                            • ITEM_AMOUNT (Amount in document currency): 350.00

                                                                            • QUANTITY (Quantity): 3

                                                                            • PO_UNIT (PO unit of measure): SU

                                                                            • Second account assignment for service B:
                                                                              • INVOICE_DOC_ITEM (Document item in invoice document): 000004

                                                                              • SERIAL_NO (Running number of the account assignment): 03

                                                                              • TAX_CODE (Tax code): V1

                                                                              • ITEM_AMOUNT (Amount in document currency): 350.00

                                                                              • QUANTITY (Quantity): 3

                                                                              • PO_UNIT (PO unit of measure): SU

                                                                              • For more information, see the parameter documentation for the tablesHeaderData,ItemData, and AccountingData,or refer to the SAP Library under Logistics Invoice Verification.

                                                                                Example: Incoming invoice for a one-time vendor
                                                                                This example shows you how to proceed in order to enter and post aninvoice for a one-time vendor.
                                                                                It is not necessary to populate the AddressData table. If you donot enter any data in the AddressData table, the address data forthe one-time vendor from the purchase order is adopted 1:1 in theinvoice.
                                                                                If you use the AddressData table for the data transfer, theaddress data for the one-time vendor is read from the purchase orderinto the invoice and is then overwritten or supplemented by the fieldsin the AddressData table.
                                                                                The purchase order for the one-time vendor contains the name 'SAP AG',postal code '60000', and the street and building number 'Neurottstraße16'. You receive an invoice with the one-time vendor address as follows:Name 'SAP AG', postal code '69190', and place 'Walldorf'. Enter thefollowing data:
                                                                                AddressData table
                                                                                ACC_1_TIME (One-time vendor indicator): X
                                                                                NAME (Name): SAP AG
                                                                                POSTL_CODE (Postal code): 69190
                                                                                CITY (Place): Walldorf
                                                                                The invoice is posted with the following one-time vendor address data:Name 'SAP AG', street and building number 'Neurottstraße 16', postalcode '69190', place 'Walldorf'.
                                                                                For more information, see the parameter documentation for the tableAddressData.

                                                                                Example: Incoming invoice for different payee
                                                                                This example shows you which address data you must enter in theAddressData table in order to enter and post an invoice for adifferent payee.
                                                                                You receive an invoice for the different payee with the name 'SAP AG',postal code '69190', place 'Walldorf', bank number '38070724', andaccount number '4711'. Enter the following data:
                                                                                AddressData table
                                                                                ACC_1_TIME (One-time vendor indicator): ' '
                                                                                NAME (Name): SAP AG
                                                                                POSTL_CODE (Postal code): 69190
                                                                                CITY (Place): Walldorf
                                                                                BANK_NO (Bank number): 38070724
                                                                                BANK_ACCT (Bank account number): 4711
                                                                                For more information, see the parameter documentation for the tableAddressData.

                                                                                Meaning
                                                                                INCLUDE BAPI_KEYFIELD
                                                                                Fiscal year

                                                                                Meaning
                                                                                INCLUDE BAPI_KEYFIELD
                                                                                Document number of an invoice document
                                                                                INCLUDE 'BAPI_INCOMINGINVOICE_CREATE ADDRESSDATA' OBJECT DOKU ID FU

                                                                                Meaning
                                                                                This structure contains the header data for the invoice document to becreated.
                                                                                INCLUDE BAPI_DATAELEMENT OBJECT DOKU ID TX LANGUAGE EN
                                                                                The following fields must be populated:

                                                                                • Document date of the incoming invoice (DOC_DATE field)

                                                                                • Posting date of the incoming invoice (PSTNG_DATE field)

                                                                                • Company code (COMP_CODE field)

                                                                                • Currency key (CURRENCY field) or ISO code currency (CURRENCY_ISO field)

                                                                                • Gross invoice amount in doc. currency (GROSS_AMOUNT field)

                                                                                • The following fields can be populated:
                                                                                  • Indicator: Post invoice or credit memo (INVOICE_IND field)

                                                                                  • Document type (DOC_TYPE field)

                                                                                  • Reference document number (REF_DOC_NO field)

                                                                                  • Different invoicing party (DIFF_INV field)

                                                                                  • Directly quoted exchange rate (EXCH_RATE field)

                                                                                  • Indirectly quoted exchange rate (EXCH_RATE_V field)

                                                                                  • Automatically calculate tax (CALC_TAX_IND field)

                                                                                  • Terms of payment key (PMNTTRMS field)

                                                                                  • Base date for due date calculations (BLINE_DATE field)

                                                                                  • Discount days 1 (DSCT_DAYS1 field)

                                                                                  • Discount days 2 (DSCT_DAYS2 field)

                                                                                  • Time limit for net terms (NETTERMS field)

                                                                                  • Discount days 1 (DSCT_PCT1 field)

                                                                                  • Discount days 2 (DSCT_PCT2 field)

                                                                                  • Document header text (HEADER_TXT field)

                                                                                  • Key for payment block (PMNT_BLOCK field)

                                                                                  • Unplanned delivery costs (DEL_COSTS field)

                                                                                  • Tax code for delivery costs (DEL_COSTS_TAXC field)

                                                                                  • Jurisdiction code for delivery costs (DEL_COSTS_TAXJ field)

                                                                                  • Name of external creator in external system (PERSON_EXT field)

                                                                                  • Payment method (PYMT_METH field),,

                                                                                  • Additional payment method (PMTMTHSUPL field),,

                                                                                  • The following field should not be populated:
                                                                                    • Origin of a Logistics Invoice Verification document (IV_CATEGORY field)
                                                                                    • Value range

                                                                                      Functionality:
                                                                                      Unplanned delivery costs (DEL_COSTS)
                                                                                      1. The system distributes the unplanned delivery costs without referenceto your settings in Customizing for Logistics Invoice Verification inthe unit Configure How Unplanned Delivery Costs arePosted. These costs are distributed either among the settled items inthe invoice document or to a separate G/L account.
                                                                                      Tax code for unplanned delivery costs when posted to a separate G/Laccount
                                                                                      1. The system determines the tax code for the unplanned delivery costsfrom the DEL_COSTS_TAXC field.
                                                                                      Indicator: Post invoice or credit memo (INVOICE_IND field)
                                                                                      If an x is entered in the field INVOICE_IND, the system createsan invoice.
                                                                                      If the INVOICE_IND field is blank, the system creates a creditmemo.
                                                                                      Currency key (CURRENCY and CURRENCY_ISO fields)
                                                                                      1. The system determines the currency from the SAP format field(CURRENCY field).
                                                                                      2. The system determines the currency from the ISO format field(CURRENCY_ISO field).
                                                                                      Automatically calculate tax (CALC_TAX_IND field)
                                                                                      If the CALC_TAX_IND field contains an 'x', no data may be maintained intable TaxData.
                                                                                      Checks:
                                                                                      If you do not populate the following fields, the system determines therequired data according to the given priorities. If the system cannotdetermine any data, you receive corresponding return messages from themethod call. These are listed in the return parameter.
                                                                                      Document type (DOC_TYPE field)
                                                                                      1. The system takes the settings from Customizing in Logistics InvoiceVerification Maintain Number Assignments forAccounting Documents
                                                                                      Invoicing party (DIFF_INV field)
                                                                                      1. The system determines the invoicing party from the header data of thefirst purchase order (ITEMDATA table).
                                                                                      Exchange rate (EXCH_RATE field)
                                                                                      1. The system determines the exchange rate from the fixed rate in thepurchase order.
                                                                                      2. The system determines the exchange rate from the daily exchange rate.
                                                                                      Terms of payment
                                                                                      1. The system determines the terms of payment from the PMNTTRMS fieldorthe DSCT_DAYS1, DSCT_DAYS2, DSCT_PCT1, or DSCT_PCT2 fields.
                                                                                      2. The system determines the terms of payment from the first purchaseorder.
                                                                                      Baseline date for payment
                                                                                      1. If the base date for due date calculation (field BLINE_DATE) ispopulated, the system determines the baseline date for payment from thebase date for due date calculation.
                                                                                      2. If the terms of payment key (PMNTTRMS field) is populated and thebase date for due date calculation (BLINE_DATE field) is blank, then thesystem determines the baseline date for payment from the terms ofpayment key.
                                                                                      3. If the terms of payment key (PMNTTRMS field) is populated and thebase date for due date calculation (BLINE_DATE field) is blank, thesystem determines the baseline date for payment from the terms ofpayment key in the first purchase order.
                                                                                      Payment block
                                                                                      1. If the key for the payment block (PMNT_BLOCK field) is populated, thesystem determines the payment block from the key for the payment block.
                                                                                      2. If the terms of payment key (PMNTTRMS field) is populated and thekeyfor payment block (PMNT_BLOCK field) is blank, the system determinesthe payment block from the terms of payment key.
                                                                                      3. If the terms of payment key (PMNTTRMS field) and the key for paymentblock (PMNT_BLOCK) field are blank, the system determines the paymentblock from the terms of payment key from the first purchase order.
                                                                                      Origin of an invoice document (IV_CATEGORY field)
                                                                                      1. The system checks whether the field is blank, and automaticallypopulates it with a 'B', meaning that the invoice document was createdusing a BAPI.

                                                                                      Description
                                                                                      This table contains account assignment data for the item data in anincoming invoice.
                                                                                      Use of this table is principally dependent on whether the purchase orderin respect of which settlement is to be effected relates to stockmaterial or consumable material. If you wish to settle a warehousetransaction, no account assignment information is necessary, and you donot need to make any entries in the AccountingData table. If youwish to effect settlement in respect of consumable material, the
                                                                                      AccountingData table is populated depending on the nature of theaccount assignment (single or multiple) and the option of changing theaccount assignment at the time of invoice receipt. The followingoverview outlines the possible combinations:

                                                                                      • Single account assignment and account assignment at the time of
                                                                                      • invoice receipt changeable
                                                                                        Prerequisite:
                                                                                        The goods receipt is non-valuated or there is no provision for goodsreceipt. Additionally, the 'Account Assignment Changeable at InvoiceReceipt' indicator (REUPD field) must be set for the account assignmentcategory used, and material for valuated special stock must not beinvolved.
                                                                                        AccountingData:
                                                                                        Optional entry. Population of the AccountingData table only makessense if you want to add unplanned account assignments to the invoicedocument. In this case, make entries according to the information belowfor the individual fields.
                                                                                        • Single account assignment and account assignment at the time of
                                                                                        • invoice receipt unchangeable
                                                                                          Prerequisite:
                                                                                          The goods receipt is non-valuated or there is no provision for goodsreceipt. Additionally, the 'Account Assignment Changeable at InvoiceReceipt' indicator (REUPD field) must not be set, and material forvaluated special stock must not be involved. The account assignmentcannot be changed if the goods receipt is valuated or if material forvaluated special stock is involved.
                                                                                          AccountingData:
                                                                                          No entry. The system adopts the account assignment data from thepurchase order or service entry sheet.
                                                                                          • Multiple account assignment and account assignment changeable at the
                                                                                          • time of invoice receipt
                                                                                            Prerequisite:
                                                                                            The goods receipt is non-valuated or there is no provision for goodsreceipt. Additionally, the 'Account Assignment Changeable at InvoiceReceipt' indicator (REUPD field) must be set for the account assignmentcategory used, and material for valuated special stock must not beinvolved.
                                                                                            AccountingData:
                                                                                            Mandatory entry. Make entries according to the information below for theindividual fields. This enables you avoid a random distribution ofquantities and amounts among the account assignment items
                                                                                            • Multiple account assignment and account assignment unchangeable at
                                                                                            • the time of invoice receipt
                                                                                              Prerequisite:
                                                                                              The goods receipt is non-valuated or there is no provision for goodsreceipt. Additionally, the 'Account Assignment Changeable at InvoiceReceipt' indicator (REUPD field) must not be set, and material forvaluated special stock must not be involved. The account assignment islikewise unchangeable in the case of settlement in respect of purchaseorders for services if goods receipt is valuated. Furthermore, theaccount assignment is unchangeable in the case of settlement in respectof a purchase order for material for valuated special stock.
                                                                                              AccountingData:
                                                                                              Mandatory entry. Make entries according to the information below for theindividual fields. This enables you avoid a random distribution ofquantities and amounts among the account assignment items Make sure thatyour entries match the planned account assignments from the purchaseorder or service entry sheet. The system checks this content and in theevent of variances writes a corresponding error message to the returnparameter Return.
                                                                                              Alternative entry as of Release Enterprise 4.70:
                                                                                              As of Release 4.70, you can only add information to the followingfields:
                                                                                              Document item in invoice document (INVOICE_DOC_ITEM field)
                                                                                              Sequential number of the account assignment (SERIAL_NO field)
                                                                                              Amount in document currency (ITEM_AMOUNT field)
                                                                                              If the quantity field (QUANTITY) is populated, the purchase order unit(PO_UNIT) or purchase order unit in ISO code (PO_UNIT_ISO) fields mustalso be populated.
                                                                                              Tax code (TAX_CODE field)
                                                                                              Tax jurisdiction code (TAXJURCODE field)
                                                                                              The system determines the account assignment information automaticallyfrom the purchase order or service entry sheet.
                                                                                              For each item in the incoming invoice, the system determines whether theitem has single or multiple account assignment on the basis of theassociated PO item.
                                                                                              In the case of purchase orders for external services with service-basedinvoice verification, the system checks each individual service to seewhether it has single or multiple account assignment. However, if youare not using service-based invoice verification, the check is carriedout for the service entry sheet as a whole.
                                                                                              Note:
                                                                                              If you only partially populate the fields of the AccountingDatatable, in addition to the data entered, the system adopts the data ofthe empty fields and not the account assignment data from thepurchase order.
                                                                                              The following fields must be filled:
                                                                                              • Document item in invoice document (INVOICE_DOC_ITEM field)

                                                                                              • Unplanned account assignment from invoice verification (XUNPL field) or
                                                                                              • running number of account assignment (SERIAL_NO field)
                                                                                                • Amount in document currency (ITEM_AMOUNT field)

                                                                                                • G/L account number (GL_ACCOUNT field)

                                                                                                • If the quantity field (QUANTITY) is populated, the purchase order unit
                                                                                                • (PO_UNIT) or purchase order unit in ISO code (PO_UNIT_ISO) fields mustalso be populated.
                                                                                                  • If a there is a different purchase order price unit in the purchase
                                                                                                  • order, the Quantity in PO Price Unit (PO_PR_QNT), Purchase Order PriceUnit (PO_PR_UOM) and PO Price Unit in ISO Code (PO_PR_UOM_ISO) fieldsmust be populated.
                                                                                                    The following fields can be populated:
                                                                                                    • Tax code (TAX_CODE field)

                                                                                                    • Tax jurisdiction code (TAXJURCODE field)

                                                                                                    • If the Quantity in Purchase Order Price Unit (PO_PR_QNT) field is
                                                                                                    • populated, the Purchase Order Price Unit (PO_PR_UOM) field or thePurchase Order Price Unit in ISO Code (PO_PR_UOM_ISO) field must also bepopulated.
                                                                                                      The following fields are populated with the input values of thecalling program in the account assignment table:
                                                                                                      • Cost center (COSTCENTER field)

                                                                                                      • SD document number (SD_DOC field)

                                                                                                      • SD document item (SDOC_ITEM field)

                                                                                                      • Main asset number (ASSET_NO field)

                                                                                                      • Asset subnumber (SUB_NUMBER field)

                                                                                                      • Order number (ORDERID field)

                                                                                                      • Reference date for settlement accounting (REF_DATE field)

                                                                                                      • Commitment item (CMMT_ITEM field)

                                                                                                      • Funds center (FUNDS_CTR field)

                                                                                                      • Functional area (FUNC_AREA field)

                                                                                                      • Funds (FUND field)

                                                                                                      • Business area (BUS_AREA field)

                                                                                                      • Internal key for Real Estate object (RL_EST_KEY field)

                                                                                                      • Controlling area (CO_AREA field)

                                                                                                      • Cost object (COSTOBJEKT field)

                                                                                                      • Network number for account assignment (NETWORK field)

                                                                                                      • Activity number (ACTIVITY field)

                                                                                                      • Profitability segment number (CO-PA) (PROFIT_SEGM_NO field)

                                                                                                      • Profit center (PROFIT_CTR field)

                                                                                                      • Work breakdown structure element (WBS_ELEM field)

                                                                                                      • Grant (GRANT_NBR field)

                                                                                                      • Commitment item (CMMT_ITEM_LONG field)

                                                                                                      • Function area (FUNC_AREA_LONG field)

                                                                                                      • FM: Budget period (BUDGET_PERIOD field)

                                                                                                      • Delivery creation date (DEL_CREATE_DATE field)

                                                                                                      • INCLUDE BAPI_DATAELEMENT

                                                                                                        Value range
                                                                                                        Order unit and order price unit
                                                                                                        The system checks whether the purchase order unit (PO_UNIT field) or theorder unit in ISO code (PO_UNIT_ISO) matches the PO unit of theassociated purchase order.
                                                                                                        The system checks whether the purchase order price unit (PO_PR_UOM) orthe purchase order price unit in ISO code (PO_PR_UOM_ISO field) matchesthe purchase order price unit of the associated purchase order.
                                                                                                        In the case of a purchase order for external services, the system checkswhether the purchase order unit (PO_UNIT field) or the order unit in ISOcode (PO_UNIT_ISO) is the same as the PO unit of the associated serviceentry sheet.
                                                                                                        Unplanned account assignment from invoice verification (XUNPL field)or running number of account assignment (SERIAL_NO field)
                                                                                                        Examples of entries:
                                                                                                        A purchase order item has threefold account assignment.

                                                                                                        • You wish to change the existing account assignment:

                                                                                                        • In the XUNPL field, enter ' ' and then enter the line that you wish tochange (for example, '2') in the SERIAL_NO field.
                                                                                                          • You wish to add an unplanned account assignment:

                                                                                                          • Enter 'X' in the XUNPL field and leave the SERIAL_NO field blank.
                                                                                                            Checks
                                                                                                            If you do not enter any data in the following fields, the systemdetermines the data according to the specified priorities. If the systemcannot determine any data, the system returns relevant messages from themethod call. These are listed in the return parameters.
                                                                                                            Tax code
                                                                                                            1. The determines the tax code from the TAX_CODE field.
                                                                                                            2. The system determines the tax code from the associated purchaseorder.

                                                                                                            Description
                                                                                                            This table enables you to supply the enhancement fields from table IVEXTwithout modifications.

                                                                                                            Description
                                                                                                            This table contains the G/L account data for an incoming invoice.
                                                                                                            If you also want to post to a G/L account for a PO item, enter therequired postings in the GlAccountData table.
                                                                                                            Note:
                                                                                                            For more information on the meaning of the individiual parameter fields,see the relevant data element documentation in the ABAP Dictionary.
                                                                                                            The following fields must be populated:

                                                                                                            • Document item in invoice document (INVOICE_DOC_ITEM field)

                                                                                                            • G/L account from G/L accounting (GL_ACCOUNT field)

                                                                                                            • Debit/credit indicator (DB_CR_IND field)

                                                                                                            • Company code (COMP_CODE field)

                                                                                                            • Tax code (TAX_CODE field)

                                                                                                            • The following fields can be populated:
                                                                                                              • Amount in document currency (ITEM_AMOUNT field)

                                                                                                              • Indicator: Negative posting (NEG_POSTNG field)

                                                                                                              • Tax jurisdiction code - tax location for calculation of taxes (field
                                                                                                              • TAXJURCODE)
                                                                                                                • Item text (ITEM_TEXT field)

                                                                                                                • Cost center (COST_CENTER field)

                                                                                                                • SD document number (SD_DOC field)

                                                                                                                • SD document item (SDOC_ITEM field)

                                                                                                                • Order number (ORDERID field)

                                                                                                                • Reference date for settlement (REF_DATE field)

                                                                                                                • Commitment item (CMMT_ITEM_LONG field)

                                                                                                                • Funds center (FUNDS_CTR field)

                                                                                                                • Function area (FUNC_AREA_LONG field)

                                                                                                                • Profit center (PROFIT_CTR field)

                                                                                                                • Funds (FUND field)

                                                                                                                • Business area (BUS_AREA field)

                                                                                                                • Business area of business partner (TR_PART_BA field)

                                                                                                                • Cost object (COSTOBJECT field)

                                                                                                                • Network plan number for account assignment (field NETWORK field)

                                                                                                                • Activity number (ACTIVITY field)

                                                                                                                • WBS element (WBS_ELEM field)

                                                                                                                • Service type (ACTTYPE field)

                                                                                                                • Internal key for Real Estate object (RL_EST_KEY field)

                                                                                                                • Personnel number (PERSON_NO field)

                                                                                                                • Business process (CO_BUSPROC field)

                                                                                                                • Grant (GRANT_NBR field)
                                                                                                                • Value range
                                                                                                                  Checks
                                                                                                                  If the system cannot determine any data, the system returns relevantmessages from the method call. These are listed in the return parameter.
                                                                                                                  Document item in invoice document (field INVOICE_DOC_ITEM)
                                                                                                                  The field must be populated with values in ascending order.

                                                                                                                  Description
                                                                                                                  With this table, you pass on the data for the items of the incominginvoice.
                                                                                                                  INCLUDE BAPI_DATAELEMENT OBJECT DOKU ID TX LANGUAGE EN
                                                                                                                  The following fields must be populated:

                                                                                                                  • Invoice document number (INVOICE_DOC_ITEM field)

                                                                                                                  • Purchase order number (PO_NUMBER field)

                                                                                                                  • Purchasing document item number (PO_ITEM field)

                                                                                                                  • Amount in document currency (ITEM_AMOUNT field)

                                                                                                                  • If the quantity field (QUANTITY) is populated, the order unit (PO_UNIT)
                                                                                                                  • or order unit in ISO code (PO_UNIT_ISO) fields must be populated aswell.
                                                                                                                    • If there is a different order price unit in the purchase order, the
                                                                                                                    • quantity in order price unit (PO_PR_QNT) and order price unit(PO_PR_UOM) or order price unit in ISO code (PO_PR_UOM_ISO) fields mustbe populated as well.
                                                                                                                      • If goods receipt-based invoice verification has been defined, the
                                                                                                                      • following fields must be populated:
                                                                                                                        Document number of a reference document (REF_DOC)
                                                                                                                        Fiscal year of the current period (REF_DOC_YEAR)
                                                                                                                        Reference document item (REF_DOC_IT)
                                                                                                                        • If planned delivery costs are posted for a purchase order, the fields
                                                                                                                        • level number (COND_ST_NO) and condition counter (COND_COUNT) or thefield condition type (COND_TYPE) must be populated.
                                                                                                                          (You can interpret the values for the fields from database table KONVfor condition and transaction data.)
                                                                                                                          • For business transactions involving a purchase order for external
                                                                                                                          • services and service-based invoice verification, if the service entrysheet number field (SHEET_NO) is populated then the line number field(SHEET_ITEM) must also contain a value.
                                                                                                                            The following fields can be populated:
                                                                                                                            • Document number of a reference document (REF_DOC field)

                                                                                                                            • Fiscal year of the current period (REF_DOC_YEAR field)

                                                                                                                            • Reference document item (REF_DOC_IT field)

                                                                                                                            • Indicator: subsequent debit/credit (DE_CRE_IND field)

                                                                                                                            • Tax code (TAX_CODE field)

                                                                                                                            • Tax jurisdiction code # location for tax calculation (TAXJURCODE field)

                                                                                                                            • If the quantity in order price unit (PO_PR_QNT) field is populated, the
                                                                                                                            • order price unit (PO_PR_UOM) or order price unit in ISO code(PO_PR_UOM_ISO) fields must be populated as well.
                                                                                                                              • Item Text (ITEM_TEXT field)

                                                                                                                              • Final Invoice Indicator (FINAL_INV field)

                                                                                                                              • Clearing Indicator for GR/IR Posting for External Services
                                                                                                                              • (GRIR_CLEAR_SRV field)
                                                                                                                                • Indicator: posting line not cash discount-relevant (CSHDIS_IND field)
                                                                                                                                • Value range
                                                                                                                                  Functionality:
                                                                                                                                  Creating subsequent debits and credits
                                                                                                                                  If you enter an X in the DE_CRE_IND field in table ItemDataand an X for posting an invoice in the INVOICE_IND field intable HeaderData, then the system creates a subsequent debit.This means that the amount to be invoiced is apportioned among thequantities already for which settlement has already been effected.
                                                                                                                                  If you enter an X in the DE_CRE_IND field in table ItemDataand leave the INVOICE_IND field in table HeaderData blank,then the system creates a subsequent credit.
                                                                                                                                  Checks:
                                                                                                                                  Order unit and order price unit
                                                                                                                                  1. The system checks that the order unit (PO_UNIT field) or order unitin ISO code (PO_UNIT_ISO field) is the same as the order unit in therelevant purchase order.
                                                                                                                                  2. The system checks that the order price unit (PO_PR_UOM field) or theorder price unit in ISO code (PO_PR_UOM_ISO field) is the same as theorder price unit in the relevant purchase order.
                                                                                                                                  Invoice document number (INVOICE_DOC_ITEM field)
                                                                                                                                  This field must be populated with ascending values.
                                                                                                                                  Posting of purchase order items or planned delivery costs
                                                                                                                                  1. If the fields condition type (COND_TYPE), level number (COND_ST_NO),and condition counter (COND_COUNT) are blank, the system creates aninvoice for a purchase order item.
                                                                                                                                  2. If the fields for the level number (COND_ST_NO field) and conditioncounter (COND_COUNT field) or condition type (COND_TYPE field) arepopulated, the system creates an invoice for a purchase order item withplanned delivery costs.
                                                                                                                                  If you do not enter any data in the following fields, the systemdetermines the data according to the priorities specified. If the systemcannot determine any data, it returns appropriate return messages fromthe method call. These are listed in the return parameter.
                                                                                                                                  Tax code
                                                                                                                                  Priority:
                                                                                                                                  1. The system determines the tax code from the TAX_CODE field.
                                                                                                                                  2. The system determines the tax code from the relevant purchase order.

                                                                                                                                  Description
                                                                                                                                  This table contains the material account data for an incoming invoice.
                                                                                                                                  If you also want to post to a material account for a PO item, enter therequired postings in the MaterialData table.
                                                                                                                                  Note:
                                                                                                                                  For more information on the meaning of the individiual parameter fields,see the relevant data element documentation in the ABAP Dictionary.
                                                                                                                                  The following fields must be populated:

                                                                                                                                  • Document item in invoice document (INVOICE_DOC_ITEM field)

                                                                                                                                  • Material (MATERIAL field)

                                                                                                                                  • Valuation area (PLANT field)

                                                                                                                                  • Debit/credit indicator (DB_CR_IND field)

                                                                                                                                  • Quantity (QUANTITY field)

                                                                                                                                  • Base unit of measure (BASE_UOM field)

                                                                                                                                  • Base unit of measure in ISO code (BASE_UOM_ISO field)

                                                                                                                                  • Tax code (TAX_CODE field)

                                                                                                                                  • The following fields can be populated:
                                                                                                                                    • Valuation type (VALUATION_TYPE field)

                                                                                                                                    • Amount (ITEM_AMOUNT field)

                                                                                                                                    • Tax jurisdiction code - tax location for calculation of taxes
                                                                                                                                    • (TAXJURCODE field)

                                                                                                                                      Value range
                                                                                                                                      Checks
                                                                                                                                      If the system cannot determine any data, it returns relevant messagesfrom the method call. These are listed in the return parameter.
                                                                                                                                      Document item in invoice document (INVOICE_DOC_ITEM field)
                                                                                                                                      The field must be populated with values in ascending order.

                                                                                                                                      Description
                                                                                                                                      INCLUDE BAPI_TABLE OBJECT DOKU ID TX LANGUAGE EN

                                                                                                                                      Value range
                                                                                                                                      Type,,ID,,Number,,Message
                                                                                                                                      E,,M8,,366,,Payment terms are incorrect
                                                                                                                                      E,,M8,,334,,Do not populate field IV_CATEGORY
                                                                                                                                      E,,M8,,367,,Enter the line numbers in the table
                                                                                                                                      ,,,,,,in ascending order
                                                                                                                                      E,,M8,,368,,Populate field XUNPL or SERIAL_NO
                                                                                                                                      ,,,,,,for PO item & <(>&<)>
                                                                                                                                      E,,M8,,332,,Planned del.costs for PO item & <(>&<)>
                                                                                                                                      ,,,,,,were incorrectly defined.
                                                                                                                                      Other possible messages
                                                                                                                                      The system might also display messages from other function modules orprograms, for example:
                                                                                                                                      Type,,ID,,Number,,Message
                                                                                                                                      E,,ME,,706,,Item & for PO document & does not exist &DEFAULT&
                                                                                                                                      Default

                                                                                                                                      Description
                                                                                                                                      This table contains the tax information for the invoice to be created.
                                                                                                                                      INCLUDE BAPI_DATAELEMENT
                                                                                                                                      The following fields have to be populated:

                                                                                                                                      • Tax code (TAX_CODE field)

                                                                                                                                      • Tax amount in document currency (TAX_AMOUNT field)

                                                                                                                                      • The following fields can be populated:
                                                                                                                                        • Tax base amount in document currency (TAX_BASE_AMOUNT field)

                                                                                                                                        • Condition type (COND_TYPE field)

                                                                                                                                        • Tax jurisdiction (TAXJURCODE field)

                                                                                                                                        • Tax jurisdiction code - location for tax (TAXJURCODE_DEEP field)

                                                                                                                                        • Document item number for tax document (ITEMNO_TAX field)
                                                                                                                                        • Description
                                                                                                                                          With this table, you pass on the data of the incoming invoice if youwish to distribute the gross amount among several creditor lines.
                                                                                                                                          INCLUDE BAPI_DATAELEMENT OBJECT DOKU ID TX LANGUAGE DE
                                                                                                                                          The following fields must be populated:

                                                                                                                                          • Grouping key for split in the vendor line (SPLIT_KEY field)

                                                                                                                                          • You following fields can be populated:
                                                                                                                                            • Gross invoice partial amount in document currency (SPLIT_AMOUNT field)

                                                                                                                                            • Payment method (PYMT_METH field)

                                                                                                                                            • Tax code (TAX_CODE field)

                                                                                                                                            • Payment conditions key (PMNTTRMS field)

                                                                                                                                            • Additional payment method (PMTMTHSUPL field)
                                                                                                                                            • Value range
                                                                                                                                              Grouping key for amount split
                                                                                                                                              If you want to distribute the withholding tax between several vendorlines, then you must use the same grouping key (SPLIT_KEY) for theamount split as for the withholding tax: The line numbers for thegrouping key must be entered in ascending order.

                                                                                                                                              Description
                                                                                                                                              With this table, you pass on the withholding data of the incominginvoice. This can be, for example, information for calculatingemployment tax or capital gains tax.
                                                                                                                                              INCLUDE BAPI_DATAELEMENT OBJECT DOKU ID TX LANGUAGE EN
                                                                                                                                              The following fields must be populated:

                                                                                                                                              • Grouping key for split in the vendor line (SPLIT_KEY field)

                                                                                                                                              • The following fields can be populated:
                                                                                                                                                • Indicator for withholding tax type (WI_TAX_TYPE field)

                                                                                                                                                • Withholding tax code (WI_TAX_CODE field)

                                                                                                                                                • Withholding tax base amount (WI_TAX_BASE field)

                                                                                                                                                • Withholding tax amount in document currency (WI_TAX_AMT field)

                                                                                                                                                • Withheld withholding tax in doc. currency (WI_TAX_WITHHELD_AMT field)
                                                                                                                                                • Value range
                                                                                                                                                  Grouping key (SPLIT_KEY)
                                                                                                                                                  If you want to enter more than one line for the withholding tax, youmust enter the grouping key in ascending order.
                                                                                                                                                  If you want to distribute the withholding tax among several vendorlines, you must enter the same grouping key for the amount split(SPLIT_KEY) that was used for the withholding tax.
                                                                                                                                                  Withholding tax type (WI_TAX_TYPE) and withholding tax code(WI_TAX_CODE)
                                                                                                                                                  The withholding tax type contains the calculation rule for determiningwithholding tax. This means that the vendor can be exempted fromwithholding tax at certain times. This information is stored in thevendor master record.
                                                                                                                                                  If you enter a withholding tax code, you must also enter a withholdingtax type.
                                                                                                                                                  If the withholding tax code (WI_TAX_CODE) contains a value, then thewithholding tax base amount (WI_TAX_BASE) must also be populated.
                                                                                                                                                  If the withholding tax code (WI_TAX_CODE) is blank, then the withholdingtax amount in the document currency (WI_TAX_AMT) and the withholding taxbase amount (WI_TAX_BASE) must be zero.

1528384MRM_BAPI: Separation of corrections for TM integration
1528385MRM_BAPI: Separation of corrections for TM integration
1075141BAPIs valid for usage with AFS6.0
1432631BUS2081: Address data of incoming invoice
830717BAPI: Classic withholding tax
381593MIRO/MIR7/MIRA: Batch Input is not possible
870051BAPI_INCOMINGINVOICE_PARK: BAdI does not run
813758MIR6: Difference display is missing
809438MIR6: difference displayed incorrectly
634150MIR7: Document number gaps in the parking
555270BAPI: Entry of negative quantities
486726BAPI: Direct posting to material or G/L account
402363BAPI_INCOMING_INVOICE_CREATE: item amount