I’ve seen this error message crop up a few times. It occurs when you try to receive a Purchase Order in Receiving Transactions Entry and you are presented with the message below even though “Purchase Order Approvals” hasn’t been activated in the “Purchase Order Enhancement” module
As mentioned in several articles online it can be caused because a budget hasn’t been assigned in the “Commitment Setup” window for the year of the Purchase Order you are trying to receive against. Therefore if you go into “Commitment Setup” and assign a budget to the relevant year the issue is resolved. However, on some occasions I’ve found missing records in the commitment table causing the issue. (perhaps because several Purchase Orders have been raised whilst the Commitment Setup was missing a budget for that year)
At first I tried running “Checklinks” on the Purchase Order Enhancements tables via “Microsoft Dynamics GP > Maintenance > Purchase Order Enhancements” however when this failed I’ve fixed the issue by manually inserting data into the commitment tables based on data in the Purchase Order line table.
Just in case anyone else encounters the same issue I thought I’d share the script I’ve used.
INSERT INTO cpo10110 (ponumber, ord, actindx, reqdate, vendorid, approvl, committed_amount, polnesta, qtycance, unitcost, postedsubtotal) SELECT pop.ponumber, pop.ord, pop.invindx, pop.reqdate, pop.vendorid, '1', pop.extdcost, pop.polnesta, pop.qtycance, pop.unitcost, 0.00 FROM pop10110 pop LEFT JOIN cpo10110 poe ON pop.ponumber = poe.ponumber AND pop.ord = poe.ord WHERE pop.polnesta IN ( 1, 2 ) AND poe.ponumber IS NULL
As you can see this SELECTs data from the Purchase Order Line table (POP10110) and inserts into the Commitment tables (CPO10110) where its missing from the Commitment table (CPO10110).
As with any script that updates data please ensure you have a good backup of your data prior to running this. I’d also recommend testing this in a TEST company as well before implementing in the LIVE or production company.
Its also a good idea to just run the SELECT portion of the script in the first instance and see if it highlights the PO you are trying to receive against. If it does you can always investigate further, for example ensuring lines aren’t cancelled or checking if there definitely is a budget setup for the year of the purchase order. You also need to ensure the line item has a valid account number.
You can also adapt the script and change the WHERE clause so it just includes the POs you know to have the problem.
I hope this comes in handy for someone else in the future.
Thanks for reading