Dynamics NAV Sleuthing: Change Log
In the previous entry of this series, Dynamics NAV Sleuthing: Navigating Record Information, we covered the various ways one might investigate the source of a posted entry and a very basic way to see the last date a master record might have been changed. However, the most powerful tool for identifying changes to non-posted information is the Change Log.
The Change Log in Dynamics NAV allows us to identify which tables or fields are important to track and what specifically to track about each one. Unfortunately, the Change Log is not turned on by default in a NAV database. If it was not activated during or since your original implementation, you can quickly activate it at any time. Doing so has virtually no ramifications until you define which tables are logged. Search for Change Log Setup and check the box.
Once the change log is active, we can assign tables to it. From Change Log Setup, select the “Tables” option from the ribbon.
From this (admittedly long) list of tables, you can specifically select those you wish to log. For starters, I always recommend that all setup tables are fully logged (Log Modification, All Fields).
For each table, you define if logging is active for inserts, modifications and/or deletions. Within each of the three categories, you can also select “All Fields” or “Some Fields”. For relatively small or low volume tables, “All Fields” is the best and most efficient approach. For tables with higher volume, you should consider a more prudent approach of “Some Fields” to limit the size of the log history and any potential impact on performance.
When “Some Fields” is selected as an option, the Assist-Edit button to the right of the field is also available (the button with the three dots). Using the Assist-Edit button, you are then able to select the specific fields to be logged.
Once the Change Log has been activated for a table, all future inserts, modifications, and deletes to that table will be recorded (once individual users log out of NAV and back in) – per the definition you provided in the setup. To see history, you are able to open the “Change Log Entries” page by searching or navigating from the Departments menu.
The image above illustrates the change log entries for a customer record where the name was changed and a phone number was added.
- Start conservatively. If the table or field is high use or very unlikely to be important enough to investigate, do not include it. For the tables you do include, try adding just the critical fields and review the change log after a week. Then increase the fields as needed.
- Only include posted tables or high-use document tables if they are necessary. These will cause the log to grow very quickly. For investigations of posted transactions, it is much better to start with the tools described in part 1 of this series: Dynamics NAV Sleuthing: Navigating Record Information
- Get comfortable searching the Change Log Entries page. The view can be unwieldy at first and you will find it much more useful once you have had some practice using it.
- Periodically use the “Delete Change Log Entries” option in NAV to remove older log records – once it is unlikely that period will likely not need to be revisited. The tool allows for filtering, so you can more surgically specify which log history to purge.
- If you have any more questions about Dynamics NAV Sleuthing: Change Log, contact us at Stoneridge Software