When developing reports in Microsoft Dynamics 365 Business Central, performance and scalability are crucial—especially in cloud environments where system efficiency impacts everything from responsiveness to cost. One often-overlooked feature that can significantly enhance report performance is the DataAccessIntent property.
What Is DataAccessIntent?
The DataAccessIntent property is available on report objects in AL. It specifies how a report should access the database—whether it’s read-only or read-write.
The property supports two values:
ReadOnly
When you set DataAccessIntent = ReadOnly, you are explicitly telling the platform that your report only needs to read data from the database and will not perform any write operations.
Why is this important?
ReadWrite
If your report needs to modify data during execution—a rare scenario—you should use DataAccessIntent = ReadWrite. This forces the report to run on the primary database.
However, you should avoid using ReadWrite unless absolutely necessary because:
When to Use Each
Scenario | Use ReadOnly? | Use ReadWrite? |
---|---|---|
Standard data listing/reporting | ![]() |
![]() |
Reports that update records | ![]() |
![]() |
Diagnostic or audit reports | ![]() |
![]() |
How to Set DataAccessIntent in AL
report 50100 "Customer Balance Report"
{
DataAccessIntent = ReadOnly;
dataset
{
dataitem(Customer; Customer)
{
column(Name; Name) { }
column(Balance; "Balance (LCY)") { }
}
}
layout
{
// Define RDLC or Word layout
}
}
By default, if you don’t specify the property, it behaves as ReadWrite. So it’s a good practice to explicitly set it to ReadOnly when applicable.
DataAccessIntent
property is only a hint to the Business Central server. The server may not always be able to use a read-only replica, even if the property is set to ReadOnly
.DataAccessIntent
set to ReadOnly
attempts to modify data, a runtime error will occur.DataAccessIntent
property can be overridden by the user through the “Database Access Intent List” page in Business Central.In short: if your report doesn’t write data, use DataAccessIntent = ReadOnly. It’s an easy win for performance and best practice compliance.
Stay tuned for more….
Original Post https://ammolhsaallvi.blog/2025/05/08/optimizing-business-central-reports-with-the-dataaccessintent-property/