Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Error while deleting Invoice in Invoice History and Matching

(0) ShareShare
ReportReport
Posted on by 2

Trying to delete a pending invoice in Invoice History and Matching Details screen. Invoice is showing up in "Waiting" Job Status and when I try to delete it I get following error:

About to update a record in table 'PurchLine' which was not selected for update (RecId is 5637156845). [W-0108]

(S)\Classes\xRecord\doUpdate
(S)\Classes\PurchLineType\setPurchStatus - line 113
(S)\Classes\PurchLineType_Project\setPurchStatus - line 5
(S)\Data Dictionary\Tables\PurchLine\Methods\setPurchStatus - line 6
(S)\Data Dictionary\Tables\VendInvoiceInfoTable\Methods\Delete - line 70
(S)\Classes\xRecord\dbOpInTransaction
(C)\Classes\FormDataSource\delete
(C)\Forms\VendInvoicePostingHistory\Data Sources\VendInvoiceInfoTable\Methods\delete - line 3
(C)\Classes\FormRun\task
(C)\Classes\SysSetupFormRun\task - line 20

Cannot edit a record in Purchase order lines (PurchLine).
The operation cannot be completed, since the record was not selected for update. Remember TTSBEGIN/TTSCOMMIT as well as the FORUPDATE clause.

Please help

*This post is locked for comments

  • Suggested answer
    Manmeet Kaur Profile Picture
    2 on at
    RE: Error while deleting Invoice in Invoice History and Matching

    Thank you ToddB. I opened a ticket with Microsoft and they had me download the hotfix mentioned in KB 3002889. That worked. I am able to delete pending invoices now.

  • Verified answer
    ToddB Profile Picture
    on at
    RE: Error while deleting Invoice in Invoice History and Matching

    Hi CJ,

    In addition, KB 3002889 is available for both AX 2012 R2 and R3; and depending on your version you would want to search for the correct install via Issue search in LCS (https://lcs.dynamics.com):

    "Cannot edit a record in Purchase order Lines (PurchLine). The operation cannot be completed since the record was not selected for update" error when trying to delete a second pending invoice.

    Thanks, Todd

  • ToddB Profile Picture
    on at
    RE: Error while deleting Invoice in Invoice History and Matching

    Hi CJ,

    Are you using AX 2012 R2?

    If so, have you taken a look at KB 2893998: Pending invoices are not saved correctly, vendor invoices duplicating, unable to post, and inquiries appearing incorrectly.
    https://lcs.dynamics.com/?si=6&fw=/kb/2893998

    Thanks, Todd

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Leaderboard > Microsoft Dynamics AX (Archived)

#1
Mohamed Amine Mahmoudi Profile Picture

Mohamed Amine Mahmoudi 100 Super User 2025 Season 1

#2
Community Member Profile Picture

Community Member 48

#3
Zain Mehmood Profile Picture

Zain Mehmood 6 Moderator

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans