I am currently setting up a new AX 2012 system with data imported from 09. I am trying to delete some of the test purchase orders that I have put in but am getting an error message " If previous versions exist, the current document cannot be deleted." when deleting the orders.
I’m trying to delete a PO, but the “delete” button in the listpage is disabled, so I try to delete the PO by using shortcut Alt + F9, but getting the error “If previous versions exist, the current document cannot be deleted.”
I try to look at the confirmation journal as you suggested, but the PO haven’t been confirmed yet, so there’s no confirmation journal.
You need to look at any transaction created from the purchase order, and remove it prior to deletion, the common one is the confirmation, you say it has not been confirmed, but that does not mean there is no confirmation journal, you need to check.
I’ve check the confirmation journal, there’s no confirmation journal or any transaction created from the purchase order. I just create a PO, and then try to delete it. I even didn’t input any line in the PO but the delete button is disabled and I can’t delete the PO.
Which delete button where? In the previous post you said you received the message about the existing versions - now you are saying there is no delete button - clearly there was a delete button when you tried to delete it earlier [:D] Could you please confirm your exact screen and problem?
Earlier I got the message because I was trying to delete a PO by using the shortcut Alt + F9. The delete button in the Purchase Order list page (Procurement and sourcing >> Common >> Purchase orders >> All purchase orders) is disabled.
I have the same situation as the OP. That is, I try to delete a cancelled PO but get the error message “If previous versions exist, the current document cannot be deleted.” As you suggest, there are, indeed, multiple confirmations. You state to remove these “versions” first, to allow the PO to be deleted. Do you know how do you remove these prior confirmations?
Take help from your developer. We need to probably delete PO records from PurchTableAllVersions, PurchLineAllVersions, VendPurchOrderJour, InventDim tables or may be more if required.
PurchTableAllVersions and PurchLineAllVersions are the views, not the table. InventDim table contains values for inventory dimensions, not inventory transactions.