web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Duplicate VendInvoiceInfoTable records created for an invoice when submitted to workflow

(0) ShareShare
ReportReport
Posted on by 505

We have run into what appears to be a bug in the pending vendor invoice function.

Following are the details :

a) After entering  a pending vendor invoice, and then submitting it -  a duplicate record of the invoice is being created in the VendInvoiceInfoTable.  

b) The duplicate record is not removed until after the Vendor invoice (VendEditInvoice) is closed.  

c) If the VendEditInvoice form is not closed and the approver approves the invoice, the workflow instance record in the WorkFlowTrackingStatusTable is  linked to the duplicate record (WorkFlowTrackingStatusTable.ContextRecId = RecId of the duplicate record in VendInvoiceInfoTable); however, when the VendEditInvoice form is closed the duplicate record is removed, causing the record in the WorkFlowTrackingStatusTable to point to a record in  the VendInvoiceInfoTable that no longer exists.  This causes the workflow history to be orphaned from the vendor invoice that it was created for.

This issue has been duplicated in both an Ax2012 r2 and an AX2012 r2 with CU6 environment.

Has anyone else seen this?

Thanks,

Joe

*This post is locked for comments

I have the same question (0)
  • André Arnaud de Calavon Profile Picture
    301,035 Super User 2025 Season 2 on at

    Hi Joe,

    I have seen duplicate records before caused by customizations or crashed AX sessions.

    When you open an pending invoice which was edited before, indeed a duplicate record is being created. This record and also related lines do have the same information at moment of starting editing. The only difference is that the new records do have a new "parm id" filled.

    This is intended behaviour, so if you make changes and want to cancel your changes, AX knows the old version of the invoice.

    So points a and b are normal.

    I'm worried about point c. Unluckely I cannot check it because I enjoy my holiday...

    When you have finished editing normally at moment of closing the form the new records with the parm id will become the new records and the old are deleted. Also the parm id field then is being cleared.

    My worries is about presenting the right information for the approver. Can he see the new just submitted version of the invoice. Or does he approve the wrong old version?

    Maybe you or another community member can check my last comment. Otherwise I will check it within 14 days when I'm back at work.

  • JoeArnaldo Profile Picture
    505 on at

    Thank you for your reply.

    The approver is approving the correct version of the invoice.  Seems to not be a problem here.

    Regarding the VendInvoiceInfoTable.ParmId field - I dont see a way to use this as a link.  The WorkFlowTrackingStatusTable does not have any such fk field.  It only has ContextTableId and ContextRecId.

    Regards,

    Joe

  • André Arnaud de Calavon Profile Picture
    301,035 Super User 2025 Season 2 on at

    Hi Joe,

    The ParmId field is only used for version control of the invoice, not a link.

    Your problem is still: "This causes the workflow history to be orphaned from the vendor invoice that it was created for."?

  • JoeArnaldo Profile Picture
    505 on at

    Thank you Andre.

    Indeed, my problem is still "This causes the workflow history to be orphaned from the vendor invoice that it was created for."

    Ultimately, I need a report that shows the final approver of a vendor invoice; however, I am seeing many records in the WorkFlowTrackingStatusTable that do not link to records in the VendInvoiceInfoTable.

    Any help you can provide is greatly appreciated.

    Thank you very much,

    Joe

  • Community Member Profile Picture
    on at

    Hello Joe,

    I would like to add 'my two cents' in this matter.

    Frequently do I encounter problems because lines are getting stuk in this table.

    After research did I came to the conclusion that this occurred during client crashes while a invoice was being submitted to the workflow.

    The orphanated workflow table - vendinvoicetable does also occur, in this case will the line in the workflowtable be deleted.

    The client crash problem has been fixed with a kernel Hotfix.

    Best regards,

    Martien Janssen

  • community Profile Picture
    141 on at

    Hi Joe ,
    we are also facing the same issue s in CU7 , pending invoices are not validating anything when submitting &  approval ie, the user can submit/approve while  1- there is not budget & the line is marked by red X 2-  3way matching has matching issues  3- invoices are duplicated & can be saved in this status

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans