Personalized Community is here!
Quickly customize your community to find the content you seek.
Now Available in Community - New TechTalk Videos for 2021
2020 Release Wave 2Discover the latest updates and new features to Dynamics 365 planned through March 2021.
Release overview guides and videos Release Plan | Preview 2020 Release Wave 2 TimelineWatch the 2020 Release Wave 2 virtual launch event
Ace your Dynamics 365 deployment with packaged services delivered by expert consultants. | Explore service offerings
Connect with the ISV success team on the latest roadmap, developer tool for AppSource certification, and ISV community engagements | ISV self-service portal
The FastTrack program is designed to help you accelerate your Dynamics 365 deployment with confidence.
FastTrack Program | Finance TechTalks | Customer Engagement TechTalks | Upcoming TechTalks
EDIT (November 2020): The most update version of this content you will now find on our official documentation. Please refer to this article: https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/sysadmin/cleanuproutines
In Dynamics 365 for Finance and Operations cleanup routines are available across various modules within the product. It is important to note that these cleanup routines should be only executed after detailed analysis and confirmation from the business this data is no longer needed. Also always test each routine first in test environment prior executing it in production. This article provides an overview on what is available today.
Periodic tasks > Notification clean up
This is used to periodically delete records from tables EventInbox and EventInboxData. Recommendation would also be if you don’t use Alert functionality to disable Alert from Batch job.
Periodic tasks > Batch job history clean-up
The regular version of batch job history clean-up allows you to quickly clean all history entries older than a specified timeframe (in days). Any entry that was created prior to – will be deleted from the BatchJobHistory table, as well as from linked tables with related records (BatchHistory and BatchConstraintsHistory). This form has improved performance optimization because it doesn’t have to execute any filtering.
Periodic tasks > Batch job history clean-up (custom)
The custom batch job clean-up form should be used only when specific entries need to be deleted. This form allows you to clean up selected types of batch job history records, based on criteria such as status, job description, company, or user. Other criteria can be added using the Filter button.
Inquiries > Database > Database Log > Clean up log
You can delete database logs as required. You can delete logs for specific tables, delete specific types of database logs, or delete logs based on the date and time when they were created. Note: Records that have been electronically signed can't be deleted from logs.
Data management workspace > Job history cleanup
Available in Platform update 29 and later, functionality must be enabled in Feature management and Feature name is “Execution history cleanup”.
The job history clean-up functionality in data management must be used to schedule a periodic cleanup of the execution history. This functionality replaces the previous staging table clean-up functionality, which is now deprecated. The following tables will be cleaned up by the clean-up process:
Data management workspace > “Staging cleanup” tile
The Staging cleanup functionality should no longer be used, it is depreciated. Instead use Job history cleanup
Periodic tasks > Clean up > Work creation history purge
This is used to delete work creation history records from WHSWorkCreateHistory table based on number of days to keep the history provided on dialog.
Periodic tasks > Clean up > Containerization history purge
This is used to delete containerization history from WHSContainerizationHistory table based on number of days to keep the history provided on dialog.
Periodic tasks > Clean up > Wave batch cleanup
This is used to clean up batch job history records related to Wave processing batch group.
Periodic tasks > Clean up > Cycle count plan cleanup
This is used to clean up batch job history records related to Cycle count plan configurations.
Periodic tasks > Clean up > Mobile device activity log cleanup
This is used to delete mobile device activity log records from WHSMobileDeviceActivityLog table based on number of days to keep the history provided on dialog.
Periodic tasks > Clean up > Work user session log cleanup
This is used to delete work user session records from WHSWorkUserSessionLog table based on number of hours to keep provided on dialog.
Periodic tasks > Clean up > Calculation of location load
WMSLocationLoad table is used in tracking weight and volume of items and pallets. Summation of load adjustments job can be run to reduce the number of records in the WMSLocationLoad table and improve performance.
Periodic tasks > Clean up > Inventory journals cleanup
It is used to delete posted inventory journals.
Periodic tasks > Clean up > Inventory settlements cleanup
It is used to group closed inventory transactions or delete canceled inventory settlements. Cleaning up closed or deleted inventory settlements can help free system resources.
Do not group or delete inventory settlements too close to the current date or fiscal year, because part of the transaction information for the settlements is lost.
Closed inventory transactions cannot be changed after they have been grouped, because the transaction information for the settlements is lost.
Canceled inventory settlements cannot be reconciled with finance transactions if canceled inventory settlements are deleted.
Periodic tasks > Clean up > Inventory dimensions cleanup
This is used to maintain the InventDim table. To maintain the table, delete unused inventory dimension combination records that are not referenced by any transaction or master data. The records are deleted regardless of whether the transaction is open or closed.
Inventory dimension combination record that is still referenced cannot be deleted because when an InventDim record is deleted, related transactions cannot be reopened.
Periodic tasks > Clean up > Dimension inconsistency cleanup
This is used to resolve dimension inconsistencies on inventory transactions that have been financially updated and closed. Inconsistencies might be introduced when the multisite functionality was activated during or before the upgrade process. Use this batch job only to clean up the transactions that were closed before the multisite functionality was activated. Do not use this batch job periodically.
Periodic tasks > Clean up > On-hand entries cleanup
This is used to delete closed and unused entries for on-hand inventory that is assigned to one or more tracking dimensions. Closed transactions contain the value of zero for all quantities and cost values, and are marked as closed. Deleting these transactions can improve the performance of queries for on-hand inventory. Transactions will not be deleted for on-hand inventory that is not assigned to tracking dimensions.
Periodic tasks > Clean up > Warehouse management on-hand entries cleanup
Deletes records in the InventSum and WHSInventReserve tables. These tables are used to store on-hand information for items enabled for warehouse management processing (WHS items). Cleaning up these records can lead to significant improvements of the on-hand calculations.
Periodic tasks > Clean up > On-hand entries aggregation by financial dimensions
Tool to aggregate InventSum rows with zero quantities.
This is basically extending the previously mentioned cleanup tool by also cleaning up records which have field Closed set to True!
The reason why this is needed is basically because in certain scenarios, you might have no more quantities in InventSum for a certain combination of inventory dimensions, but there is still a value. In some cases, these values will disappear, but current design does allow values to remain from time to time.
If you for example use Batch numbers, each batch number (and the combined site, warehouse, etc.) creates a new record in InventSum. When the batch number is sold, you will see quantity fields are set to 0. In most cases, the Financial/Physical value field is also set to 0, but in Standard cost revaluation or other scenarios, the value field may show some amount still. This is valid, and is the way Dynamics 365 for Finance and Operations handles the costs on Financial inventory level, e.g. site level.
Inventory value is determined in Dynamics 365 for Finance and Operations by records in InventSum, and in some cases Inventory transactions (InventTrans) when reporting inventory values in the past. In the above scenario, this means that when you run inventory value reports, Dynamics 365 for Finance and Operations looks (initially) at InventSum and aggregates all records to Site level, and reports the value for the item per site. The data from the individual records on Batch number level are never used. The tool therefore goes through all InventSum records, finds the ones where there is no more quantity (No open quantities field is True). There is no reason to keep these records, so Dynamics 365 for Finance and Operations finds the record in InventSum for the same item which has the same Site, copies the values from the Batch number level to the Site level, and deletes the record. When you now run inventory value reports, Dynamics 365 for Finance and Operations still finds the same correct values. This reduced number of InventSum records significantly in some cases, and can have a positive impact on performance of any function which queries this table.
Periodic tasks > Clean up > Cost calculation details
Used to clean up cost calculation details.
Periodic tasks > Clean up ledger journals
It deletes general ledger, accounts receivable, and accounts payable journals that have been posted. When you delete a posted ledger journal, all information that’s related to the original transaction is removed. You should delete this information only if you’re sure that you won’t have to reverse the ledger journal transactions.
Sales and marketing
Periodic tasks > Clean up > Delete sales orders
It deletes selected sales orders.
Periodic tasks > Clean up > Delete quotations
It deletes selected quotations.
Periodic tasks > Clean up > Delete return orders
It deletes selected return orders.
Periodic tasks > Clean up > Sales update history cleanup
It deletes old update history transactions. All updates of confirmations, picking lists, packing slips, and invoices generate update history transactions. These transactions ca be viewed in the History on update form.
Periodic tasks > Clean up > Order events cleanup
Cleanup job for order events. Next step is to remove the not needed order events check-boxes from Order event setup form.
Periodic tasks > Clean up > Production journals cleanup
It is used to delete unused journals.
Periodic tasks > Clean up > Production orders cleanup
It is used to delete production orders that are ended.
Periodic tasks > Clean up > Clean up registrations
It is recommended to clean up registrations periodically. The clean-up function does not delete data that is not processed. Make sure that you do not delete registrations that may be required later for documentation purposes.
Periodic tasks > Clean up > Archive future registrations
It is used to remove future registrations from the raw registrations table.
Procurement and sourcing
Periodic tasks > Clean up > Purchase update history cleanup
This is used to delete all updates of confirmations, picking lists, product receipts, and invoices generate update history transactions.
Periodic tasks > Clean up > Delete requests for quotations
It is used to delete requests for quotation (RFQs) and RFQ replies. The corresponding RFQ journals are not deleted, but remain in the system.
Periodic tasks > Clean up > Draft consignment replenishment order journal cleanup
It is used to cleanup draft consignment replenishment order journals.
Business Applications communities