topic hubAL Developmentofficial - Microsoftreviewed - checked by Opus

Developing reports

Developing reports in AL for Business Central: report objects, datasets, layouts (Word, Excel, RDL), request pages, report extensions, substitution, obsoleting, telemetry, performance, testing and troubleshooting. It answers how to build, extend, format, expose, monitor and retire reports.

Path: Development > Programming in the AL language > Developing reports · tier official · system development · narrative reviewed (checked by Opus)

Overview

A report in AL is built from a dataset (data items and columns taken from tables), one or more layouts (Word, Excel, RDL or custom), and an optional request page where users set options and filters. The Reports overview, Report Design Overview and Report object pages introduce these parts, and the walkthrough on designing a report from multiple tables shows an RDL report from dataset to totals and an Excel layout.

Subtopics go deeper on single areas: formatting report data, report layouts, discoverability (how users find reports), triggers and events, and how users run, print and save reports. Further pages cover extending reports with report extension objects, substituting reports through an event, and obsoleting reports and layouts.

For running reports in production, the telemetry, performance and troubleshooting pages explain how to find slow or failing runs. The test reports page covers verifying output with a report dataset library. Start with Reports overview and Report object, then move to dataset and layouts.

Key points

  • A report combines a dataset (data items and columns), layouts (Excel, Word, RDL) and a request page.
  • Report extension objects add columns, data items, triggers, request page elements and layouts to existing reports; a worked food inventory example shows the table and report extension code.
  • Report substitution uses the OnAfterSubstituteReport event in Codeunit 44 ReportManagement; from 2021 release wave 1, report extensions are an alternative.
  • Obsoleting reports uses ObsoleteReason, ObsoleteTag and ObsoleteState, with layout-level obsolescence from 2025 release wave 1; deprecation is also communicated via captions, search terms and help content.
  • Request pages let users set options and filters before a report runs, using properties such as RequestFilterFields and SaveValues; teaching tips, help links and saved settings are also covered.
  • Report generation telemetry tracks successful, failed and canceled runs, dataset and rendering time, SQL execution, and output formats, and supports performance analysis.
  • Performance strategies include read scale-out, background scheduling and query optimization.
  • Testing uses Codeunit 131007 Library - Report Dataset, with methods like RunReportAndLoad and AssertElementWithValueExists.

Subtopics

More Learn pages

Videos, posts and code changes

Linked by a Haiku matcher with a grounding quote from the item’s summary (link/topics.ts); machine-generated.

Business Central pages and reports

The pages, reports and queries this hub’s Learn pages name (ms.search.form, API reference), joined to the code by exact object id (data/index/docs-objects.json); a page shows the table it runs on.

Source: Microsoft Learn (CC BY 4.0). Descriptions are Learn’s own.

What Learn documents here 8 of 54 Learn pages

Show 32 more