Has anyone had any experience (luck) improving the performance of Query object 1501 "Workflow Instance"? I'm working here with NAV 2016. As I investigate the performance of various processes I often find calls to this object account for a sizable portion of the processing time. This seems to be checking if a Workflow needs to be executed based on a table that has been updated.
The process I am focused on currently is a simple Excel import that loads a bunch of records into a General Journal batch. The calls to Query 1501 account for almost 40% of the processing time. Looking at the execution plan is SSMS suggested adding an index for "[Workflow Code]" to the [Workflow Step Instance] table. Along with several included columns. I tested that with and without the included columns. While it did improve the query when run in SSMS, it did not seem to have any noticeable improvement in NAV.
Improvement of this query would likely have a fairly global improvement on overall performance as it appears to get executed rather often.
There are no bugs - only undocumented features.
0
Comments
Dynamics NAV, MS SQL Server, Wherescape RED;
PRINCE2 Practitioner - License GR657010572SG
GDPR Certified Data Protection Officer - PECB License DPCDPO1025070-2018-03
Nonetheless try adding an index for Workflow Code to the Workflow Step Instance AND make it clustered.
Dynamics NAV, MS SQL Server, Wherescape RED;
PRINCE2 Practitioner - License GR657010572SG
GDPR Certified Data Protection Officer - PECB License DPCDPO1025070-2018-03
You could match this with Approval Entry table (the relation is Workflow Step Instance ID on Approval Entry =ID on Workflow Step / Workflow Step Instance) and delete everything in Workflow Step / Workflow Step Instance not found in Approval Entry
Dynamics NAV, MS SQL Server, Wherescape RED;
PRINCE2 Practitioner - License GR657010572SG
GDPR Certified Data Protection Officer - PECB License DPCDPO1025070-2018-03
Thanks for the help.
https://support.microsoft.com/en-us/help/3202891/cumulative-update-13-for-microsoft-dynamics-nav-2016-build-47256
Made a huge difference in performance.
B.R