Table Regions
A table region renders records from any Business Central table as a live rectangle on the sheet, re-queried on every recalculation. It is the workhorse region: a report list, a data-entry surface with write-back, or an off-screen "feeder" whose totals drive KPI formulas.
Setup
Open the region's Settings (or create one with the New Region wizard):
| Field | Meaning |
|---|---|
| Range | Only the top-left cell is used — width comes from the fields, height from the records. |
| Table No. / Table Name | The Business Central table that fills the region. |
| Company | The company whose records fill the region. Blank reads the company you are working in. Accepts [Address] — a ?FIELD(Company, Name) slicer switches it from the sheet. A region reading another company is read-only — see Reading Another Company. |
| Table View | Optional sorting and filters, built with the view builder (AssistEdit) — see Filters and Sorting below. Accepts [Address] cell references: WHERE(Customer No.=FILTER([B3])). |
| Allow Table Editing | Opt-in write-back (off by default). See below. |
| Layout | Rows lays each record across a row, fields as columns. Columns lays each record down a column, fields as rows. |
| Max Rows | Records per page (default 1000). |
| Include Headers | Whether the first row (or column) shows the field captions. |
Filters and Sorting: the View Builder
The AssistEdit button on Table View opens the view builder — a replacement for Business Central's filter page that understands the sheet:
- Every field of the table is a row, with a Filter column and a Sort column. Rows carrying a setting are bold. Show switches between all fields, only those with a filter or sort, or one class (Normal, FlowFields, FlowFilters); Find Field narrows the list by name or caption.
| - The Filter column's lookup offers what fits the field. A field with a table relation opens the related table's lookup page (a customer, an item, a dimension value) — each pick is OR-ed onto the filter, so three picks give `10000 | 20000 | 30000. An option or enum field lists its options. A Boolean asks Yes/No. A date field opens a From..To dialog with presets (This Month, Last Year, Year to Date, ...) whose bounds can also be cells. A number offers quick comparisons (>0, <>0`, ...). Other codes and texts list the values the table actually holds. |
|---|
- The AssistEdit button on the Filter column (or the Insert Cell Reference action) picks a cell on the sheet and inserts it as
[Address]. The platform filter page rejects such tokens; the builder accepts them, and validates only plain filters against the field type — a typo like1..xon a date field is reported on its field immediately. - Sort: type
1on the field to sort by first,2for the tie-breaker, and so on — or use Sort by This Field. Typing a position that is taken shifts the other sorted fields down. Sort Direction applies to the whole sort, as in Business Central itself. Only normal (stored) fields sort; FlowFields cannot. - The Resulting View at the bottom shows the text the region stores —
SORTING(Due Date) ORDER(Descending) WHERE(Open=FILTER(true),Due Date=FILTER(..[C2]))— and can be edited directly; the rows follow.
- Filter Syntax shows a cheat sheet: 1000..1999, `A |
B | C, <>X, >100, son, @son, 'Foo, Inc.' (literal), '' (blank), [B4]`. |
|---|
Dates in filters are always written as yyyy-mm-dd; the date dialog does this for you. A view written earlier by hand or by the agent opens in the builder as it is — a filter on a field the table no longer has stays listed as unknown field and is written back unchanged.
The same builder serves the pivot region's table view and the FlowField region's filters.
Worked Example: Overdue Invoices
A collections list that is always current:
| Setting | Value |
|---|---|
| Region ID | OVERDUE |
| Range | A4 |
| Table | Cust. Ledger Entry |
| Fields | Customer No., Customer Name, Document No., Due Date, Remaining Amt. (LCY) |
| Table View | SORTING(Due Date) WHERE(Open=FILTER(Yes),Due Date=FILTER(..[C2])) |
With C2 holding a ?DATE-> slicer (default shortcut: the work date), the list shows every open invoice due on or before the picked date, oldest first. Above the region: =OVERDUE.Count and =OVERDUE.TableSum("Remaining Amt. (LCY)") give the invoice count and the total exposure over the whole filtered set. Ctrl+click a row to open the ledger entry.
Sorting in a table view uses the table's stored fields — FlowFields like Balance (LCY) cannot be sorted here. For top-N-by-amount lists, use a pivot region with Sort Rows by Total, or a SQL region with
ORDER BY.
The Field List
The Fields part of the setup dialog defines the region's columns, in order:
- Pick fields with the lookup, or use Add Fields to append several at once (Ctrl/Shift multi-select). Typing a field's name, caption or number in either the number or name column resolves it.
- Caption optionally overrides the header text.
- Move Up / Move Down reorder the columns; inserting between rows works too.
- The read-only Cell column shows where each field lands on the sheet at the region's anchor row — the address to use when writing a virtual column's formula.
- Format gives the column a number format (the same compact format a cell style carries — see Number Formats). Every data cell the column renders picks it up; a format set on an individual cell wins.
- Read Only keeps the column read-only even when the region allows editing — for a column users may look at but must not change. Journal and document regions set it for columns the standard page does not plainly let you edit.
Virtual columns
A field row of type Virtual adds a column that is not backed by a table field:
- Its name is free text and becomes the header.
- Its cells are edited like ordinary spreadsheet cells, but each value is stored per record (keyed to the record's SystemId), so it follows its record through sorting, filtering and paging.
- Virtual values are sheet data — editing them never requires Allow Table Editing and never touches the database.
- A virtual column can carry a Formula, applied to every row that has no value of its own. It is written against the anchor-row addresses shown in the Cell column —
=G4 * 1.25on a region anchored at row 4 means "this row's G times 1.25". A value or formula typed into an individual cell overrides it for that record. Formulas typed into cells keep the usual copy semantics: relative references shift to wherever the record renders,$pins hold. TableSumcan total a virtual column by its name across the whole filtered set — including rows the column formula computes on demand.
Editing and Write-Back
With Allow Table Editing on, region cells become editable and edits are validated into the record — running the field's OnValidate logic — then saved with Modify(true). Rules:
- Only Normal-class, enabled fields outside the primary key are writable. FlowFields, key fields and disabled fields render read-only.
- Blanking a database-backed cell is ignored (it never clears the field).
- Option and enum fields accept a caption, a name or an ordinal.
- A rejected edit (validation error, permission) is reported on the sheet after the recalculation; the database is untouched.
Formulas that write back
Typing a formula into a writable region cell stores the formula and writes its computed result back to the field after every evaluation. The formula is bound to the record that was shown when you typed it: if paging, sorting or filtering later puts a different record at that address, the write-back stops rather than hitting the wrong record. The result is only written when it differs from what the record already holds.
When a write-back changes a record, the sheet re-reads its regions and evaluates again in the same recalculation, so the record's other fields — a line amount the quantity's validation recomputed, a document total — show their new values at once, and formulas that read them see the fresh figures. A stable sheet takes one pass; a recalculation that wrote something takes two. The extra passes stop after three, so a formula whose write-back keeps changing the very value it reads cannot loop.
Paging
The region shows one page of Max Rows records at a time; pager controls on the region badge appear when more records follow. The current page is session state — it is not saved with the document — and it clamps automatically when filters shrink the data.
Formulas over Table Regions
=ID.Count— the number of records after the region's filters.=ID.TableSum("Field Name")— the sum of a numeric field (or a virtual column, by name) over the region's whole filtered set, not just the rendered page. Works on FlowFields.=ID.FieldName— a field of the region's first record.XLOOKUPwith both ranges inside the same table region searches the whole filtered table, not just the rendered rows — see Functions.
The feeder pattern
A powerful dashboard technique: place a 1-row, headerless table region off-page (for example from column AA) purely to expose a filtered set to formulas. One feeder per aggregate scope — per aging bucket, per month, per status — each read with TableSum. The dashboard's visible cells then reference those results.
Example — a three-bucket receivables aging block. Three feeders over Cust. Ledger Entry, each at Max Rows 1, headers off, parked at AA1, AB1, AC1:
| Feeder ID | Table View |
|---|---|
CUR |
WHERE(Open=FILTER(Yes),Due Date=FILTER([C2]..)) |
D30 |
WHERE(Open=FILTER(Yes),Due Date=FILTER([AA3]..[AA4])) |
D60P |
WHERE(Open=FILTER(Yes),Due Date=FILTER(..[AA5])) |
With C2 a ?DATE slicer and AA3:AA5 computing the bucket edges — as XML-formatted text, so the filter parses on every machine: =Format(CalcDate('<-30D>', C2), 0, 9) and friends — the visible dashboard cells read =CUR.TableSum("Remaining Amt. (LCY)"), =D30.TableSum("Remaining Amt. (LCY)"), =D60P.TableSum("Remaining Amt. (LCY)") — three live aging totals, no export.
Drill-Down
Every cell rendered from a record is drillable: Ctrl+click opens the record's own page (its card or list). Cells the user has overwritten with formulas keep the drill of the record beneath them.