Hello,
See if you can reproduce this error....
1. Create a Purchase Order.
2. Add an item and a unit cost. (for example 100 pieces for $10 each = $1,000 total amount, not tax liable)
3. Add a line discount % (say 10%)
4. Post receipt for all 100 pieces.
5. Post invoice for 50 pieces.
6. Post invoice for the remaining 50 pieces which should close out the order.
You should have two posted purchase invoices.
Each one should have $50 discounted.
Instead the first invoice posted $100 discount, and the second one $50 discount, for a total of $150.
150/1000 NOT EQUAL 10%!
Is there something I'm doing wrong or is the posting routine incorrect?
As always your feedback is greatly appreciated.
- Reinhard
Nav6.2
P&P Setup: Discount Posting = All Discounts
There are no other vendor, payment, etc. discounts.
0
Answers
Basically, the first time posting a partial invoice in a purch. line with a discount %, the entire discount was taken for the whole quantity.
The reason appears to be, in codeunit 90, Purch.-Post, function:
AddSalesTaxLineToSalesTaxCalc(PurchLine : Record "Purchase Line";FirstLine : Boolean)
MaxInvQty is the total quantity remaining to be invoiced. The first time you invoice an order, MaxInvQty will ALWAYS equal Quantity:
Proposed Solution
I commented out the condition and always reset the line discount amount. Appears to post correctly for partial and full invoices.
Feedback is appreciated. Is it a real bug? If so, how to report?
Maybe someone else could help with this.
Really sorry, since I'm not in NSC anymore.
Andwian