I found a flaw in my program where it’s not clearing out the record from the PickedOrders table when I unpick a sales order from my code using the IssueReturn BO.
As such, I need a way to delete the record from the PickedOrders table.
Using the BL Tester, when I enter the info to DeleteByID, it’s throwing an error when I delete the record but it still performs the delete:
SQL (record count is 11):
Epicor code rarely ever calls DeleteByID. Instead, the Epicor code will set the RowMode to a ‘D’ and then call Update. Not all BOs allow Delete but try the RowMode D, Update path to see if you have better results…
I tried a GetByID to return the dataset and then I set the RowMod to D. When invoking Update, it throws a very similar, if not the same, error. In this case, it doesn’t delete the SQL record
I used the issue return adapter to do the heavy lifting of the unpick and it does remove it from a picked state but doesn’t remove the picked order record.
I’ll take a look at what you said; which bo does that use?
For what it’s worth - i know it’s already been determined, but the decomp for that service does in fact show that all Deletion functions are explicitly written to throw that exception. For that matter, the Update() function is the same.
Here’s how I ended up doing it. It’s basically what the handheld Unpick Transaction thing does which utilizes the IssueReturn and UnpickTransaction BO’s. The UnpickTransaction BO is sort of interesting all the methods basically alter a payload that it’s carrying so it’s more simple than I had originally thought.