{"id":637,"date":"2018-03-01T13:25:23","date_gmt":"2018-03-01T18:25:23","guid":{"rendered":"https:\/\/www.apcdynamics.com\/articles\/?p=637"},"modified":"2018-03-01T13:25:23","modified_gmt":"2018-03-01T18:25:23","slug":"job-queue-deleted-dynamics-nav-2017","status":"publish","type":"post","link":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/","title":{"rendered":"Job Queue Being Deleted in Dynamics NAV 2017"},"content":{"rendered":"<h3><strong>Overview<\/strong><\/h3>\n<p>As more of our clients are going live with NAV2017, we&#8217;re finding some inconsistencies on the features that were working as we thought it should, verses the way it&#8217;s working now.<\/p>\n<p>One of such feature is the Job Queue function. Note that this only applies to NAV 2017, they&#8217;ve since rewrote how this process works in NAV 2018.<\/p>\n<p>The purpose of a job queue is to run processes automatically at a preset time. For the process to run continuously, you would need to set the job to run as Recurring.<\/p>\n<p><a href=\"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/JobQueueRecurring.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-638\" src=\"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/JobQueueRecurring.jpg\" alt=\"\" width=\"737\" height=\"612\" srcset=\"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/JobQueueRecurring.jpg 737w, https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/JobQueueRecurring-300x249.jpg 300w\" sizes=\"auto, (max-width: 737px) 100vw, 737px\" \/><\/a><\/p>\n<p>If you do not set the job queue entry as recurring, it would delete the Job Queue Entry because the process is only a one time deal. This feature was added because the users are now allowed to schedule their reports using job queue. Some reports\/processes only needed to be ran once for the user.<\/p>\n<h3><strong>The Problem<\/strong><\/h3>\n<p>After the clients went live, we started noticing the jobs that were set to recurring was being deleted as well. This confused the hell out of us because there were nothing on MSDN that talks about Job Queue Entries that are deleted when it&#8217;s set to Recurring.<\/p>\n<p>Digging into this, the problem is on <strong>Codeunit\u00a0453 &#8211;\u00a0Job Queue &#8211; Enqueue<\/strong>. More specifically, a function called\u00a0<strong>RemoveFailedJobs<\/strong>.<\/p>\n<p><a href=\"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/RemoveFailedJobs.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-639\" src=\"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/RemoveFailedJobs.jpg\" alt=\"\" width=\"837\" height=\"429\" srcset=\"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/RemoveFailedJobs.jpg 837w, https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/RemoveFailedJobs-300x154.jpg 300w, https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/RemoveFailedJobs-768x394.jpg 768w\" sizes=\"auto, (max-width: 837px) 100vw, 837px\" \/><\/a><\/p>\n<p>Looking at this, the system will remove any Job Queue Entry records that it runs into an error. So this means that at any given point if your mission critical job fails, it&#8217;ll simply remove it from running ever again&#8230;<\/p>\n<p>Yes, I could&#8217;ve setup notifications to warn you if something failed&#8230; I didn&#8217;t need to do this extra step before..<\/p>\n<p>This is a steep contrast to how Dynamics NAV Job Queue ran before. In addition, this is not how NAV 2018 behaves now.<\/p>\n<h3>Conclusion<\/h3>\n<p>You can comment out the code completely or just add the following code:<\/p>\n<blockquote><p>JobQueueEntry2.SETRANGE(&#8220;Recurring Job&#8221;,FALSE);<\/p><\/blockquote>\n<p>Doing this, the process will leave the jobs that are set to Recurring alone.<\/p>\n<p>I&#8217;m not sure if Microsoft has address this in the later CU releases for Dynamics NAV 2017, but if not, I would highly recommend you modify the code so your mission critical processes does not simply disappear!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Overview As more of our clients are going live with NAV2017, we&#8217;re finding some inconsistencies on the features that were working as we thought it should, verses the way it&#8217;s working now. One of such feature is the Job Queue function. Note that this only applies to NAV 2017, they&#8217;ve since rewrote how this processRead more<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[1],"tags":[],"class_list":["post-637","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Job Queue Being Deleted in Dynamics NAV 2017 | Confessions of a Dynamics 365 Business Central Consultant<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alex Chow\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/\"},\"author\":{\"name\":\"Alex Chow\",\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/#\\\/schema\\\/person\\\/aef29f75349626d15235713ce1db83f0\"},\"headline\":\"Job Queue Being Deleted in Dynamics NAV 2017\",\"datePublished\":\"2018-03-01T18:25:23+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/\"},\"wordCount\":379,\"commentCount\":10,\"publisher\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/wp-content\\\/uploads\\\/2018\\\/03\\\/JobQueueRecurring.jpg\",\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/\",\"url\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/\",\"name\":\"Job Queue Being Deleted in Dynamics NAV 2017 | Confessions of a Dynamics 365 Business Central Consultant\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/wp-content\\\/uploads\\\/2018\\\/03\\\/JobQueueRecurring.jpg\",\"datePublished\":\"2018-03-01T18:25:23+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/wp-content\\\/uploads\\\/2018\\\/03\\\/JobQueueRecurring.jpg\",\"contentUrl\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/wp-content\\\/uploads\\\/2018\\\/03\\\/JobQueueRecurring.jpg\",\"width\":737,\"height\":612},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/job-queue-deleted-dynamics-nav-2017\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Uncategorized\",\"item\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/category\\\/uncategorized\\\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Job Queue Being Deleted in Dynamics NAV 2017\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/#website\",\"url\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/\",\"name\":\"APC Dynamics | Dynamics 365 Business Central Consultant\",\"description\":\"Dynamics 365 Business Central experts. Less Talk. More Results.\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/#organization\",\"name\":\"APC Dynamics\",\"url\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/wp-content\\\/uploads\\\/2025\\\/05\\\/APCLogo216.png\",\"contentUrl\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/wp-content\\\/uploads\\\/2025\\\/05\\\/APCLogo216.png\",\"width\":216,\"height\":216,\"caption\":\"APC Dynamics\"},\"image\":{\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/APCommerceInc\\\/\",\"https:\\\/\\\/www.linkedin.com\\\/company\\\/ap-commerce-inc-\\\/\",\"https:\\\/\\\/www.youtube.com\\\/channel\\\/UCkM_LLmB4333D4Arjk0knyw\\\/about\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/#\\\/schema\\\/person\\\/aef29f75349626d15235713ce1db83f0\",\"name\":\"Alex Chow\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f72fa4e27588610bb80f41bb4e562d9b82762fe530709098d99963bd2da6f86f?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f72fa4e27588610bb80f41bb4e562d9b82762fe530709098d99963bd2da6f86f?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f72fa4e27588610bb80f41bb4e562d9b82762fe530709098d99963bd2da6f86f?s=96&d=mm&r=g\",\"caption\":\"Alex Chow\"},\"sameAs\":[\"https:\\\/\\\/www.apcommerce.com\\\/\"],\"url\":\"https:\\\/\\\/www.apcdynamics.com\\\/articles\\\/author\\\/admin\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Job Queue Being Deleted in Dynamics NAV 2017 | Confessions of a Dynamics 365 Business Central Consultant","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/","twitter_misc":{"Written by":"Alex Chow","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/#article","isPartOf":{"@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/"},"author":{"name":"Alex Chow","@id":"https:\/\/www.apcdynamics.com\/articles\/#\/schema\/person\/aef29f75349626d15235713ce1db83f0"},"headline":"Job Queue Being Deleted in Dynamics NAV 2017","datePublished":"2018-03-01T18:25:23+00:00","mainEntityOfPage":{"@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/"},"wordCount":379,"commentCount":10,"publisher":{"@id":"https:\/\/www.apcdynamics.com\/articles\/#organization"},"image":{"@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/#primaryimage"},"thumbnailUrl":"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/JobQueueRecurring.jpg","inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/","url":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/","name":"Job Queue Being Deleted in Dynamics NAV 2017 | Confessions of a Dynamics 365 Business Central Consultant","isPartOf":{"@id":"https:\/\/www.apcdynamics.com\/articles\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/#primaryimage"},"image":{"@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/#primaryimage"},"thumbnailUrl":"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/JobQueueRecurring.jpg","datePublished":"2018-03-01T18:25:23+00:00","breadcrumb":{"@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/#primaryimage","url":"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/JobQueueRecurring.jpg","contentUrl":"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2018\/03\/JobQueueRecurring.jpg","width":737,"height":612},{"@type":"BreadcrumbList","@id":"https:\/\/www.apcdynamics.com\/articles\/job-queue-deleted-dynamics-nav-2017\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.apcdynamics.com\/articles\/"},{"@type":"ListItem","position":2,"name":"Uncategorized","item":"https:\/\/www.apcdynamics.com\/articles\/category\/uncategorized\/"},{"@type":"ListItem","position":3,"name":"Job Queue Being Deleted in Dynamics NAV 2017"}]},{"@type":"WebSite","@id":"https:\/\/www.apcdynamics.com\/articles\/#website","url":"https:\/\/www.apcdynamics.com\/articles\/","name":"APC Dynamics | Dynamics 365 Business Central Consultant","description":"Dynamics 365 Business Central experts. Less Talk. More Results.","publisher":{"@id":"https:\/\/www.apcdynamics.com\/articles\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.apcdynamics.com\/articles\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.apcdynamics.com\/articles\/#organization","name":"APC Dynamics","url":"https:\/\/www.apcdynamics.com\/articles\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.apcdynamics.com\/articles\/#\/schema\/logo\/image\/","url":"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2025\/05\/APCLogo216.png","contentUrl":"https:\/\/www.apcdynamics.com\/articles\/wp-content\/uploads\/2025\/05\/APCLogo216.png","width":216,"height":216,"caption":"APC Dynamics"},"image":{"@id":"https:\/\/www.apcdynamics.com\/articles\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/APCommerceInc\/","https:\/\/www.linkedin.com\/company\/ap-commerce-inc-\/","https:\/\/www.youtube.com\/channel\/UCkM_LLmB4333D4Arjk0knyw\/about"]},{"@type":"Person","@id":"https:\/\/www.apcdynamics.com\/articles\/#\/schema\/person\/aef29f75349626d15235713ce1db83f0","name":"Alex Chow","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/f72fa4e27588610bb80f41bb4e562d9b82762fe530709098d99963bd2da6f86f?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/f72fa4e27588610bb80f41bb4e562d9b82762fe530709098d99963bd2da6f86f?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/f72fa4e27588610bb80f41bb4e562d9b82762fe530709098d99963bd2da6f86f?s=96&d=mm&r=g","caption":"Alex Chow"},"sameAs":["https:\/\/www.apcommerce.com\/"],"url":"https:\/\/www.apcdynamics.com\/articles\/author\/admin\/"}]}},"_links":{"self":[{"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/posts\/637","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/comments?post=637"}],"version-history":[{"count":1,"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/posts\/637\/revisions"}],"predecessor-version":[{"id":640,"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/posts\/637\/revisions\/640"}],"wp:attachment":[{"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/media?parent=637"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/categories?post=637"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.apcdynamics.com\/articles\/wp-json\/wp\/v2\/tags?post=637"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}