Stop price update of  delivered but un-invoiced (non-invoiced) line items

Hi Gurus,
I need some help regarding price update of line items which are delivered but not invoiced yet.
Case 1:
I am calling the FM 'BAPI_SALESORDER_CHANGE' and passing the line item (say 10) whose price needs to be updated. This line item is neither delivered nor invoiced. Result, correct change of price for line item 10.
Case 2:
In the above order, i am adding another line item (say 30), which is completely delivered, but I have not yet created an invoice for it. I want that this line item's price should not be changed (as delivery is already created for it). So, in my price update report, I check and filter this line item (10) and pass only line item 30 to the BAPI. Result: not only line item 30 but line item 10 also gets updated with new price!!
Case 3:
I created a new line item(40) and created an invoice for it after completely delivering it. When I call the BAPI now, I again filter the line items 30 and 40 and pass only line item 10 which i want to be updated.
Result:
Line item 10 - updated with new price
Line item 30 - updated with new price
Line item 40 - not updated
Requirement:
Any line item that is completely delivered should not be updated with the new price regardless of it having an invoice or not.
Assumptions:
I am running a custom report to find the line items that need change and calling the BAPI_SALESORDER_CHANGE and passing those line items to update the price.
Problem faced:
This process is updating all line items in the SO that are not invoiced regardless of weather I am passing it to the BAPI or not
As far as i know, the checking of the invoice is in some standard program, and hence had debugged the BAPI and got the FM SD_SALES_DOCUMENT_SAVE which in my opinion is doing the change. But on further debugging I lost track of the tables which were holding the data as the code is flowing through a number of user exits and standard forms.
Please help!

Hi Soumyo,
In Pricing Update screen, you will find pricing type X, Y and Z which you can use to define your own pricing update scenarios.  Check OSS note 24832. This note provides enough details about each of the update pricing options and also explains on how to use pricing update X, Y, and Z.  Let me know if you need any more help on this.
Thanks & Regards
Kapil Sharma
Author - Configuring SAP ERP Sales and Distribution

Similar Messages

  • Insert/Update/Delete Non-PO Invoice Line Item via FM/BAPI?

    Does anyone know of a way to insert/update/delete an Invoice Line item (Non-PO Accounting Invoice - Transaction FB60 or FV60) using a BAPI or Function Module (or set of function modules) using ABAP? I have been trying to find some code to accomplish this and am stuck on a couple of issues.
    I have found PRELIMINARY_POSTING_FB01 and PP_CHANGE_DOCUMENT_ENJ but both seem to submit the details to background processes. This is an issue because it gives the user a success message after execution but later delivers the error to Workflow. This is for an interfacing program so the results should be as real time as possible.
    Has anyone accomplished this via FM or BAPI and if so would you mind sharing your experiences?
    Thank you very much,
    Andy

    SG- Thank you for the reply.
    I have been playing with BAPI_INCOMINGINVOICE_PARK and I'm not sure if it is doing exactly what we want, but it is something that I have considered in the past. I plan on looking into BAPI_ACC_INVOICE_RECEIPT_POST this morning, hopefully that will provide some more for us.
    If possible I'd like to avoid BDC sessions because this program could hypothetically interface with multiple SAP systems with different configurations.
    I will check into those FM's and thank you very much.

  • Invoice line items report from DSO compared to Infocube (in HANA)

    Hi Folks,
    As you know Invoice line items are very granular level information. We are facing performance issues on reports based on the Infocubes to display this information. We are migrating to HANA and looking for options to improve the performance. One of the option we are looking at is instead of Infocube can we we report directly on the DSO. I would like to know whether it will help and its Pro & Con's. Please help.
    Thanks,
    B

    Hi B,
    Reading data from a DSO instead of an InfoCube will not improve reporting performance. The benefit in getting rid of the cube is that you have less loading to do.  You still need cubes for planning and inventory scenarios.
    You do not need a composite provider to report from DSOs in BW. Once you've migrated to HANA you use DSOs just as you would today, and you can report from a multiprovider. Yes, you can use a composite provider, but it is not necessary.
    If your report is slow today, you need to find out where it is slow.  HANA could provide a huge benefit as soon as you migrate, or it might not help much.  It depends on the scenario. OSS 1681396 is a good place to start.
    If the DB time is long, and you're not using BWA today, you can expect big benefits when you migrate to HANA.
    If the OLAP time is long, you might see big benefits when you migrate, as the OLAP engine during query execution is pushing more to HANA.
    If the frontend time is long, migrating to a different database isn't likely to change that, you'd need to address that separately.
    Finally, an important point to remember is that once you've migrated you open up additional possibilities for improvement that are not available to you in BW-on-non-HANA.  For example, you might be able to rewrite queries as HANA models.  I did some performance tests on this in a very simple case of exception aggregation.

  • Payment to be done according to invoice line item

    Dear SAP Friends,
    I require a small clarification on Payment. Please see the below screnario.
    1. I have a invoice for 10000 USD, Which includes 3 lines in the details.
           a. Water Charge - 3000
           b. Electricity Charge - 5000
           c. Rent Charge  -        2000.
    2. Now i receive a payment of 8000.
        Will it possible to match the invoice line item to receive the payments of 2 individual lines for 5000 and 2000.
        When i checked with our FI consultant , i saw that payment is done with respect to the whole invoice , not the individual detail line.
    Can anyone please provide some information on this.
    Thanks
    Kunaseelan.

    Hi
    Payment will be done with respect to Invoice only but not based on the Individual Line Items.
    you can do by partial or Residual Payments.
    Regards
    Venkat

  • Post non PO invoice line items using INVOIC01 and FM IDOC_INPUT_INVOIC_MRM

    hello there SAP folks,
    Have an interesting question for all of you. We currently have a partner through whom we use the IDOC_INPUT_INVOIC_MRM Function module to pass invoices. Now there are multiple line items some times [multi E1EDP01 / E1EDP02] segments which all refer to the same PO but to different line items on the PO. Now all that is well.
    For one particular partner we now have the following requirement. We are going to have the same condition as above, with the added condition that there are going to be some invoice line items with no reference to a PO. the reason is that the vendor is going to calculate the different taxes and send them to us. so when we post the invoice :
    we will now have
    31 Vendor
    40 GR/IR
    40 Tax 1
    40 Tax 2
    50 Tax 3 offset
    instead of
    31 vendor
    40 GR/IR
    to deal with the new situation I tried adding having the following
    first E1EDP02 is going to refer to the PO using qualifier 001, but second E1EDP02 [for tax] s not going to have a qualifier 001. When I do that i get a missing belnr (001) and zeile (001) error.the exact error message is the following
    Required field BELNR(001) is missing in segment E1EDP02
    Required field ZEILE(001) is missing in segment E1EDP02
    Message no. FD070
    Now to bypass that, I added the 001 qualifier for the second E1EDP02 [tax part] and now the error that I get is either the PO is duplicated or if i put some dummy PO number, then it says PO cannot be found.
    =======
    so the question is how is it possible to post  4 items in the idoc , with one being a PO reference and 3 non PO reference using INVOIC01 and IDOC_INPUT_INVOIC_MRM
    I also have to add that it is possible to add a non PO items to the MM invoice in MIRO by entering the additional tax lines using the g/l account tab next to the PO reference tab.

    nvm.
    Edited by: D N on Dec 16, 2008 2:10 PM

  • During F110  run-How to pick profit centre from the Pur.Invoice line item ?

    Could anyone please help me with a solution to this problem.
    Purchase invoice line items have got profit centre recorded from Material master.
    While doing the auto payment run F110, for foreign currency invoices, the exchange rate diff
    is posted to a - realised exch rate diff gl a/c.
    But there is no cost object attached.
    Business wants the system to pick the profit centre from the purchase invoice line item
    and put it in the line item record of the exch rate diff account.
    Can I do it using OKB9 ? Could someone please explain how to do it.
    Thanks

    Hi,
    With standard SAP this is not possible.may be you have to develop some custom program.
    with my experiance,we always post to defualt cost center.
    hope this helps you.
    Thanks,
    Rau

  • Group consolidate invoice line items

    Hi all,
    If I have multiple sales orders but all with the same characteristics at item level (material, currency etc.), and if I consilidate the sales orders during billing, will I also get a single invoice line item?  or will I get one invoice item per sales order item?
    Trying to avoid maxing out on the AR items.
    regards
    Tim

    Hi Tim,
    You will get invoice with as many items as you have in all sales order billing billed in that invoice. During posting to FI in general you will have one FI document line per item/GL account (determined from VKOA based on Customer Account Assignment Group, Material Account Assignment Group and accounting key assigned to condition type in pricing procedure) combination. You can limit number of G/L lines by applying posting aggregation for FI-SD interface. Youc an define the fields, which are not relevant for FI document and the fields will be cleared resulting in aggregation of the G/L lines on G/L account/posting sign (debit credit). Please be aware that the field you clear for aggregation will not appear in the line items in FI, so cannot be used as characteristics of the postings in the G/L.
    Regards,
    Marcin

  • Relation between Invoice Line items and Accounting Line item

    Dear All,
    My requirement is to print all the invoice documents and it's tax values like cenvat, Ecess, BED and VAT.
    I have to fetch these tax details from BSEG table .
    I' am getting Invoice number ( RBKP-BELNR ) from BKPF-AWTKEY .
    Can any one please tell me how to relate the Invoice line items and Accounting document line items..
    Any BAPI or FM is there to retrieve these data.
    Please do needful in this regard.

    Hi,
    from table bseg - field Koart
    K = Vendor
    D = Customer
    S = G/L account here tax lines identify with buzid = T
    or take table bset for taxes
    Andreas

  • Order To Cash - AR Invoice Line Item description change

    Hi,
    I have a requirement of concatenating some value to the Invoice line - Item description in the AR Invoice created thought Auto Invoicing.
    Please could anyone tell me the best way of doing it.
    Thanks & Regards,
    Genoo

    Hi Luko,
    Thanks for your response.
    I noticed that Item Description is not a free text field in Sales Order Line..
    My requirement is that I have a value which needs to be concatenated to Item Description, when we interface the Order to Receivables through Auto Invoice program.
    Any possible ways please?
    Thanks,
    Genoo

  • Q36 How do I report items delivered but not invoiced?

    Starting from scratch here...........
    The idea is too create a report of sales order items that have been delivered but not yet invoiced within a set of dates and showing sales value of goods delivered.
    My logic had told me using docstatus in ORDR and OINV would have been a good start but I was wrong!
    Thanks,
    Robin

    Hi,
    This is a query we use here - not sure if it will help but.....
    SELECT DISTINCT T1.CARDCODE, T1.CARDNAME , T8.FirstName+ ' ' +T8.LastName AS 'Sales Employee', T1.DOCNUM DELIVERY#,T1.DocStatus 'DELIVERY STATUS', T1.DOCDATE 'DELIVERY Date', T1.DocTotal 'DELIVERY Total', T3.DOCNUM Return#,T3.DocStatus 'Return Status', T3.DOCDATE 'Return Date', T3.DocTotal 'Return Total',T5.DOCNUM Invoice#,T5.DocStatus 'Invoice Status', T5.DOCDATE 'Invoice Date', (T5.DocTotal-T5.VatSum-T5.TotalExpns-T5.DiscSum) 'Total Before Discount', T5.VatSum 'Tax', T5.TotalExpns 'Freight', (T5.DocTotal - T5.PaidToDate) 'Total Payment Due', T7.DOCNUM 'CREDIT MEMO#', T7.DOCDATE
    FROM DBO.DLN1 T0
    INNER JOIN DBO.ODLN T1 ON T1.DOCENTRY = T0.DOCENTRY
    LEFT JOIN DBO.RDN1 T2 ON T2.BASEENTRY = T1.DOCENTRY
    LEFT JOIN DBO.ORDN T3 ON T2.DOCENTRY = T3.DOCENTRY
    LEFT JOIN DBO.INV1 T4 ON T4.BASEENTRY = T1.DOCENTRY
    LEFT JOIN DBO.OINV T5 ON T5.DOCENTRY = T4.DOCENTRY
    LEFT JOIN DBO.RIN1 T6 ON T6.BASEENTRY = T5.DOCENTRY
    LEFT JOIN DBO.ORIN T7 ON T7.DOCENTRY = T6.DOCENTRY
    LEFT OUTER JOIN OHEM T8 ON T1.OwnerCode = T8.EmpId
    WHERE  T1.DOCDATE >= [%0] AND  T1.DOCDATE <= [%1]
    Its just a little more information for you.
    Regards
    Sean Martin

  • Originating document number not updated for one invoice line item

    Hi,
    We have a invoice document number in which the originating document number is not updated for one of the line items ,this is order related down payment invoice .May be this is due to system inconsistency so is there any SAP note to overcome this problem.
    Best Regards,
    Rohit

    Dear All,
             I found out the problem for not updated in F-04. "While create the receipt document in GL master Open item management maintained box was not checked". It can be found in BSIS table - OI Management'.
             Is there any other way to clear this document.
    Thanks...

  • I have a Os X Lion 10.7.4 software. i tried to update the software but it says,"None of the selected items could be installed,an unexpected error occurs."

    it keeps telling me this whenever i try to click the "sofware update". it downloads,and thereafter turns into the grey screen but gives me ,"non of the selected updates could be installed."

    Two things you can try.
    - Sign out of the App Store (in the Store menu)
    - Quit the App Store
    - In Finder - Go>Go to folder...  (or Apple-shift-G)
    - Paste in the following "~/Library/Caches/ "
    - It will take you to a folder.  Delete com.apple.appstore
    - Launch the App Store and test
    Try resetting the App Store.
    Reset       Learned from Old Toad

  • Sorting Invoice line items after they've been summed

    Hi,
    I'm working on a template for the out-of-box invoice using the XML it generates. The body of the document contains the line items, and I've successfully been able to print and sum (net amount and tax) these line items by Item Description and Unit Price using the following code:
    <?for-each@section:G_INVOICE?>
    <?for-each-group:G_LINE_TOTAL;./LIST_G_LINES/G_LINES/LINE_ITEM_DESCRIPTION[../LINE_TYPE='LINE']?>
    <?for-each-group:current-group();./LIST_G_LINES/G_LINES/LINE_UNIT_SELLING_PRICE[../LINE_TYPE='LINE']?>
    <?./LIST_G_LINES/G_LINES/LINE_ITEM_DESCRIPTION[../LINE_TYPE='LINE']?>
    <?sum(current-group()/./LIST_G_LINES/G_LINES/LINE_QTY_INVOICED[../LINE_TYPE='LINE'])?>
    <?./LIST_G_LINES/G_LINES/LINE_UNIT_SELLING_PRICE[../LINE_TYPE='LINE']?>
    <?sum(current-group()/./LIST_G_LINES/G_LINES/LINE_ITEM_AMOUNT[../LINE_TYPE='LINE'])?>
    <?sum(current-group()/./LIST_G_LINES/G_LINES/LINE_EXTENDED_AMOUNT[../LINE_TYPE='TAX'])?>
    What I need to do now is also SORT the summed line items by Item Description and Unit Price, but everything I've tried is giving me errors.
    One thing I've tried is adding the SORT command to the element that is printing the Item Description as in the following:
    <?sort:./LIST_G_LINES/G_LINES/LINE_ITEM_DESCRIPTION[../LINE_TYPE='LINE'];'ascending';data-type='text'?>
    I've also tried adding a separate field to do the sorting, but I'm getting different errors then.
    Thanks in advance for any suggestions.

    Thanks! This helped to some extent.
    Adding the sort for the LINE_ITEM_DESCRIPTION after the for-each-group for it worked to sort the lines by item description, but when I added the sort command for the LINE_UNIT_SELLING_PRICE within its for-each-group, I get the following error:
    FOProcessor setLocale: en-us
    java.lang.reflect.InvocationTargetException
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at oracle.apps.xdo.common.xml.XSLT10gR1.invokeProcessXSL(XSLT10gR1.java:593)
         at oracle.apps.xdo.common.xml.XSLT10gR1.transform(XSLT10gR1.java:390)
         at oracle.apps.xdo.common.xml.XSLT10gR1.transform(XSLT10gR1.java:208)
         at oracle.apps.xdo.common.xml.XSLTWrapper.transform(XSLTWrapper.java:161)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:1019)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:972)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:211)
         at oracle.apps.xdo.template.FOProcessor.createFO(FOProcessor.java:1577)
         at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:952)
         at RTF2PDF.runRTFto(RTF2PDF.java:626)
         at RTF2PDF.runXDO(RTF2PDF.java:460)
         at RTF2PDF.main(RTF2PDF.java:251)
    Caused by: java.util.EmptyStackException
         at java.util.Stack.peek(Unknown Source)
         at java.util.Stack.pop(Unknown Source)
         at oracle.xdo.parser.v2.XSLTContext.popCurrentGroupingKey(XSLTContext.java:905)
         at oracle.xdo.parser.v2.XSLForEachGroup.processGroups(XSLForEachGroup.java:468)
         at oracle.xdo.parser.v2.XSLForEachGroup.process01(XSLForEachGroup.java:282)
         at oracle.xdo.parser.v2.XSLForEachGroup.process(XSLForEachGroup.java:210)
         at oracle.xdo.parser.v2.XSLForEachGroup.processAction(XSLForEachGroup.java:94)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLForEachGroup.processGroups(XSLForEachGroup.java:465)
         at oracle.xdo.parser.v2.XSLForEachGroup.process01(XSLForEachGroup.java:282)
         at oracle.xdo.parser.v2.XSLForEachGroup.process(XSLForEachGroup.java:210)
         at oracle.xdo.parser.v2.XSLForEachGroup.processAction(XSLForEachGroup.java:94)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLForEach.processAction(XSLForEach.java:142)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLTemplate.processAction(XSLTemplate.java:191)
         at oracle.xdo.parser.v2.XSLStylesheet.execute(XSLStylesheet.java:508)
         at oracle.xdo.parser.v2.XSLStylesheet.execute(XSLStylesheet.java:485)
         at oracle.xdo.parser.v2.XSLProcessor.processXSL(XSLProcessor.java:264)
         at oracle.xdo.parser.v2.XSLProcessor.processXSL(XSLProcessor.java:150)
         at oracle.xdo.parser.v2.XSLProcessor.processXSL(XSLProcessor.java:187)
         ... 16 more
    I would appreciate to know what is wrong with this and, also, how to interpret these errors.....is there any sort of error code manual?

  • Cheque printed but  fi document not created (line  item shows as open item)

    Hi,
    Problem Description :
    F110
    In  payment run Posting order is not matching it shows 11 generated and 10 completed .
    Due to this, document number 5100316279( i.e open item)  was not cleared but generated a cheque 809635 for 58.75
    The same document number  5100316279got cleared on  01.07.2008 ; payment run  and generated another cheque 809643 for same amount 58.75
    To summarize due to a system error we ended in a double payment to the  vendor.
    Request you  help us to solve  this issue.
    Thanks.

    Hi,
    The reason why you have more documents generated than completed is that update terminations on the executing the payment run.It means some documents were not posted in the data base. You could find the terminated update via using SM13.
    Here is some information saying what you have to do when this happens:
    You need to analyse the update record data to decide what has to be done with the update records. In order to analyse the record data, use transaction SM13 for terminated updates. By double-clicking on the terminated update records, the updates modules are displayed. By double-clicking on the function module 'POST_DOCUMENT' with error status you can see in whick line item the clearing has failed. Please use
    'Goto => Display data'. In table T_BKPF and T_BSEG are the data of the entered document. Important are CPU-Date (T_BKPF-CPUDT) and Time (T_BKPF-CPUTM). In table T_AUSZ1 is the the information which line item
    (BELNR, BUKRS, GJAHR, BUZEI) should be cleared with this update record.
    Afterwards, execute FB03 for this document and determine the clearing document BSEG-AUGBL for this line item. Analysing this clearing document with data of the terminated update records you have to decide what has to be done with this update record.
    For repeating the update task it is necessary that the clearing of the Open item is reset with transaction FBRA. Without resetting the other Clearing you will always get error F1 805 in the function module 'POST_DOCUMENT'.
    So can you please analyse the data concerning the update termination. Depending on the investigation, you have to decide, whether the data has to be re-entered or whether the update task can be deleted or whether the clearing has to be reset and the task has to be repeated.
    With regards,
    V.Krishnamoorthy

  • In A/P Invoice line items is not showing.............

    Hi All,
                There is an A/P Invoice, with no line Items. But the Document Total is Rs. 100000/-  When I check the Base Document there are 10 Line Items in GR(PO). Surprised to see this..............How is it possible. And when i open A/P Invoice base document icon also unable mode. Please do the needfull.
    Arbaaz,

    Hi Arbaaz !
    As you told that you have tracked the base document with the help of users , that this particular GRPO is the base document of that invoice . Now have you checked the target document of that particular GRPO . Is this drag you to the invoice or this is also freezed ?
    If the Target document icon is also freezed this means that your invoice is not at all linked to any GRPO , the invoice is made independently somehow ..
    Thanks
    Ashish

Maybe you are looking for