I found this issue through one of my application consultant. She wanted to delete some purchase orders that are already invoiced (fully).
Administration → IT Administration → Data Deletion → Purchase Documents → Delete Invoiced Purchase Orders Report
The report is standard one, should delete the Purchase Orders that are completely invoiced, i.e. Qty to invoice is zero, Qty to Receive also zero and Quantity=Quantity Received=Quantity Invoiced like this…!!!
But it doesn’t do this… because there is a problem…!!!
Though, its normal order, purchase line type is Item, report code will look for the field Qty. Assigned (flowfield used for Item Charge Assignment).
What I believe, in normal order it should be blank, because its used for type Charge (Item) only.
I just want to know, is it the bug or its just I am not getting the logic of the report. Report ID 499 (NAV 5.0 SP1)
I have modified as per my understanding, and add one more condition there to validate the Qty Assigned field only if purchase line type is Charge (Item).
Its deleting only for Purchase Line Type Charge (Item) , else its not deleting it…!!!
If you can open the report 499 in design mode, just check it… there will be a condition for Qty. Assigned, just check it…
I don’t think it works only when Receive and Invoice is done seperately…!!! because, it just checks for Qty. invoiced must not be zero, and Qty. Received must not be zero…!!!
I am waiting for some expert to confirm this…!!!
Thanks for your reply Ravi, but if possible for you, just check the code of the report once…!!!
If you post the receipt & invoice from the order screen and if the order is completly invoices then it is deleted automatically.
But if you manually create an invoice & use the get receipt functionality then the order is not deleted automatically.
After checking the code it seems that the lines which is totally invoices and does not have any outstanding quantity is only deleted from the purchase order where there are multiple lines.