ERPNext.com Frappe Cloud Support Partners Foundation Frappe School

Cannot delete or cancel because Purchase Order is linked with GL Entry

Hi,
I am trying to cancel a Purchase order which was linked with Payment Entry which I have already canceled . However when try to cancel the purchase order it is giving the error that it is linked to GL Entry.
I have checked in the GL entry and it has is_cancelled checked
How can I resolve the issue?

-Amit

Hi Amit,

Try cancelling the PO after deleting the Cancelled Payment entry.

Hope this helps.

Thanks

Jay

Hi JayRam,
Thanks for the reply. I tried deleting the Payment Entry. However it is giving the same error
Cannot delete or cancel because Payment Entry is linked with GL Entry.
How can we resolve this?

Thanks
-Amit

What GL Entry is linked with your Payment Entry. Find that and see if you can cancel and delete that Entry before you try cancelling the PO.

Thanks

Jay

There is no option to delete the GL Entry. Infact I will feel very uncomfortable if we have to handle GL Entries directly ourselves.

-Amit

Usually when you cancel a PO, the Payment entry should get unlinked from the PO. And you should be able to either keep the payment entry or cancel it depending on the business situation.

Which version of ERPNext are you on?

Thanks

Jay

This is how it was working before. I recently updated to version 13 and since then it has been a problem. My system is currently on

ERPNext: v13.7.1 (version-13)

Frappe Framework: v13.7.0 (version-13)

-Amit

Maybe Immutable Ledger (or something similar) has changed the game! Maybe it’s a bug.

You just have to wait for somebody more knowledgeable with the latest releases to help you with this.

Thanks

Jay

Thanks JayRam for your support and help. I really appreciate it.
I will file a bug report so that someone can look into the issue.

-Amit