Simple Object Designer Documentation
Index

Data Table Template

The Data Table template creates standalone master tables for storing custom data. This page explains how to configure and use data table features.

When to Use Data Template

Use the Data template for:

  • Master data - Customer-like records you maintain
  • Lookup tables - Reference data for dropdowns
  • Configuration tables - Settings and parameters
  • Simple lists - Any standalone data collection

Examples

Feature Purpose
Equipment Types Categorize company equipment
Training Courses List of available training
Skill Codes Employee skills reference
Cost Centers Custom cost tracking
Document Categories Classification codes

Creating a Data Table Feature

Step 1: Start Wizard

  1. Open Tasks > Create new features
  2. Click New Feature
  3. Select Data template

Step 2: Configure Feature Identity

Field Description Example
Feature Name Internal identifier "EquipmentType"
Table Caption User-visible name "Equipment Type"

Step 3: Configure Primary Key

Choose how records are identified:

Manual Entry:

  • Users enter the code manually
  • Good for: Short, meaningful codes
  • Example: "LAPTOP", "PHONE", "DESK"

Number Series:

  • System generates sequential numbers
  • Good for: Auto-numbered records
  • Example: "EQT001", "EQT002", "EQT003"

One primary key only. SOD custom tables allow exactly one primary key field. Compound or combined keys are not supported, and this is not planned to change — combined keys bring lookup and filtering complexity that is out of scope for "Simple".

Workaround: create the SOD table, then write a table extension against it to add or change the primary key.

A number series primary key must be a Code field. It also needs one more step than the wizard alone — see below.

Number Series for the Primary Key

Choosing the Number Series option in the wizard is only half the configuration.

The number series must also be assigned on your app's Setup page. Until it is, auto-numbering produces nothing even though the field is configured for it.

Where that Setup page lives: press Alt+Q, search for the name of your app, and open its Setup page. Each Data Table using a number series has its own field there.

How the setup is stored

  • SOD keeps number series configuration in a single shared setup feature for your app, not one per feature.
  • The first time you enable number series, SOD prompts you to create that setup feature.
  • On subsequent features the prompt does not appear again, because the setup feature already exists. Instead, a new field is automatically added to the existing Setup table for the new feature.

This is expected behaviour, and it explains a common report: "I enabled Use Number Series, verified with no errors, published successfully — but no setup page was created and records still require manual entry." The setup feature already existed; it is shared.

Only my first table gets numbers

Symptom: one Data Table receives automatic primary key numbers while other, seemingly identical ones do not.

Cause: the number series for those tables has not been assigned on the app's Setup page. A field existing in the Setup table does not by itself assign anything — the series must be selected there.

Fix: open the Setup page (Alt+Q → app name → Setup) and assign a number series to every Data Table that should be numbered.

Auto-numbering stopped working

Check, in order:

  1. The number series code is still linked to the feature
  2. On the Business Central No. Series page: the series has a valid line with a Starting No. (and Ending No. if used)
  3. Last No. Used has not reached the Ending No. — an exhausted series simply stops
  4. Default Nos. is enabled
  5. Use Number Series is still on in the Feature Card
  6. The number series is set up in the SOD Setup for the current company
  7. Republish the feature

After a BC major update (BC 28, for instance), re-download symbols and republish if everything above looks correct.

Step 4: Choose Generated Components

Option Description
List Page Page showing all records in a grid
Card Page Page for viewing/editing one record
API OData endpoint for external access
Add StdFactBox to List Standard FactBox panel
Add StdFactBox to Card Standard FactBox on card

FactBoxes require a Code primary key of size 20 or less. The two "Add StdFactBox" options only work when the feature's primary key is a Code field with size ≤ 20. With any other type — a Lookup field, for example — the FactBox does not render on the deployed page and there is no "i" expand control to open it.

This is a hardcoded Microsoft platform limitation that SOD cannot override.

If a FactBox does not appear: first rule out UI caching (try InPrivate mode, another browser, or another machine — Business Central caches page UI). If it still does not show, check the primary key type, correct it, and redeploy.

"Add standard FactBoxes to list page" causes SOD to include the standard Document Attachment factboxes on the generated list page. If a generated extension fails to compile against a newer BC version because a referenced standard factbox was removed by Microsoft, disabling this toggle and republishing clears the reference — but that is a workaround. The preferred fix is updating SOD, which generates the correct references and lets the toggle stay on. See Business Central Updates.

Step 5: Complete Wizard

Click Finish to create the feature with basic structure.

Feature Configuration

After wizard completes, access the Feature Card to configure:

Feature Card Settings

Field Description
Feature Feature name (read-only)
Verified Validation status
Table Caption User-visible table name
Template "Data" (read-only)
Use Number Series Primary key generation
List Page Generate list page
Card Page Generate card page
API Generate API endpoint

Modifying Settings

  1. Open Feature List
  2. Select your feature
  3. Click to edit
  4. Modify settings
  5. Republish to apply changes

Adding Fields

The Feature Fields page lets you define table fields:

Standard Fields

Data features start with a primary key field. Add additional fields:

  1. Open Feature Card
  2. Navigate to Feature Fields
  3. Add new fields

Field Configuration

Property Description
Field Name Internal name
Type Data type
Size Length for text/code
Caption Display label

See Feature Fields and Actions for details.

Common Data Table Patterns

Simple Lookup Table

Purpose: Reference codes for selection

Fields:

  • Code (primary key)
  • Description

Example: Document Category

Code        Description
INVOICE     Invoice Document
CONTRACT    Contract Document
REPORT      Report Document

Master Data Table

Purpose: Records with multiple attributes

Fields:

  • Code (primary key)
  • Name
  • Description
  • Category
  • Active (boolean)

Example: Equipment Type

Code     Name           Category      Active
LAPTOP   Laptop         Computing     Yes
PHONE    Mobile Phone   Communication Yes
DESK     Office Desk    Furniture     Yes

Configuration Table

Purpose: System settings

Fields:

  • Setting Code (primary key)
  • Value
  • Description

Example: Feature Settings

Code              Value      Description
MAX_RETRIES       3          Maximum retry attempts
DEFAULT_TIMEOUT   30         Default timeout seconds

Using Your Data Table

Accessing the List Page

After publishing:

  1. Use Tell Me (Alt+Q)
  2. Search for your feature name
  3. Open the list page

Creating Records

  1. Open the list page
  2. Click New
  3. Fill in field values
  4. Close or navigate away (auto-saves)

Editing Records

  1. Open the list page
  2. Select a record
  3. Edit directly in the list or open the card
  4. Changes save automatically

Using as Lookup

Data table features can be used as lookup sources:

Creating Lookup Fields

When adding fields to other tables:

  1. Create a field with Lookup type
  2. Reference your feature table
  3. Users can select from your data

Example

Field "Equipment Type Code" on "Equipment" table:

  • Type: Lookup
  • Related Table: Your Equipment Type feature

API Access

If API is enabled:

Endpoint Structure

https://api.businesscentral.dynamics.com/v2.0/{tenant}/{environment}/api/hougaard/{objectPrefix}/v2.0/companies({companyId})/equipmentTypes?Company={CompanyName}

Operations

  • GET - Retrieve records
  • POST - Create new record
  • PATCH - Update existing record
  • DELETE - Remove record

See API Overview for details.

Limitations

Fields cannot be auto-populated on insert

Feature-generated tables do not support giving a field a default or initial value when a record is created — setting a Date field to today's date on insert, for example.

Calculated fields on features are likewise not supported. Both are on the backlog but unavailable today.

If a field must be initialized automatically, that behaviour has to be added in AL after graduating the generated source. See Feature Fields and Actions and Graduating from SOD.

Header-to-line defaulting is not supported

In a Document feature, automatically copying a header value into a newly inserted line — a header date defaulting into a line date while remaining editable — is not possible within the current scope. See Document Table Template.

No reports or print buttons

There is currently no option to create or print a report directly from a Document or Data Table feature. The constraint is the compiler: report compilation is only supported by the Microsoft compiler, not the Legacy compiler. Capability is planned with no confirmed ETA, expected to align with the BC27 release. See Publishing Failures.

Adding a print button to a SOD Document feature is not possible without AL. The supported route is an AL extension that:

  1. declares a dependency on the app created with SOD,
  2. contains a pageextension targeting the relevant page, and
  3. adds the print action there.

See Circular Dependencies for the dependency rules that apply to such an extension.

Best Practices

Naming Conventions

  • Use clear, descriptive names
  • Follow company naming standards
  • Be consistent across features

Primary Key Design

  • Keep codes short and meaningful
  • Use a Code field of size 20 or less — required for number series and for FactBoxes
  • Use number series for auto-numbering, and remember to assign the series on the app's Setup page
  • Consider uniqueness requirements
  • Plan around the single-key limitation

Field Selection

  • Include only necessary fields
  • Provide helpful captions
  • Consider future reporting needs