Data audit system fields are added to every table in Dynamics 365 Business Central – Update

Dynamics 365 Business Central

Hi, Readers.
At the end of September, I once shared a blog about a new feature, Data audit system fields are added to every table in Dynamics 365 Business Central 2020 Release Wave 2. This time I want to update some key point. Hope this will help you.

Feature Summary

Business value:
This gives developers an easy and performant way to program against historical data, such as writing AL queries that return changed data since some specified point in time.

Feature details:
Four new system fields are added to all tables:
SystemLastModifiedOn
SystemLastModifiedBy
SystemCreatedBy
SystemCreatedOn

This is a very useful feature for internal and external audit. Although it can be done with the Change Log feature before, as everyone knows, the Change Log feature will reduce performance and increase the database capacity. Therefore, in the NAV era that Microsoft did not provide this feature, I believe all partners have manually added this function if customers need.
For Example: Customer (18)
The fields has been successfully added to the table(?).

I confirmed the system table (Field 2000000041), and they has been added.

No.FieldNameTypeLenClassEnabledType NameField CaptionRelationTableNo
2000000001SystemCreatedAtDateTime8NormalYesDateTimeCreated At0
2000000002SystemCreatedByGUID16NormalYesGUIDCreated By2000000120
2000000003SystemModifiedAtDateTime8NormalYesDateTimeModified At0
2000000004SystemModifiedByGUID16NormalYesGUIDModified By2000000120

New Update

In the previous test, I cannot customize these four fields in AL. Since these fields is stored in the Platform. But now, we can do it.
For example:
New Page:


New Report:

Page Extension:

Note: Although you can add them to the page or report, you cannot modify them because they does not exist in the actual table.

END

Hope this will help.

Thanks for your reading.

ZHU


コメント

Copied title and URL