Skip to content
Get started

Tables

A table holds records. It always lives inside one model, and its shape is defined by the attributes you create on it.

Think of a table as a sheet in a workbook, or a table in a database.

The Tables page lists tables across models, including tags, rows and the latest record commit. Select a row count to open the records. When a previous commit exists for the table, select the latest commit timestamp to compare them. Use the Model filter to show tables from one model, or select All models to show them all. Changing the model clears the selected tag filter; you can then choose a tag within that model.

Field Description Required
Name The name of the table Yes
Description Free text No
Use this as a reference table Whether the table can be referenced by others (API name: code_generation, AUTO or MANUAL) No (defaults to off / AUTO)
Identifier column name Only shown when the reference table switch is on Yes, when it is on (defaults to Code)
Display name column name Only shown when the reference table switch is on Yes, when it is on (defaults to Name)
Tags Any number of tags No

Each table receives a source_id (UUID) that identifies it permanently.

The built-in fields: identifier and display name

Section titled “The built-in fields: identifier and display name”

Every table has two fields that you can neither create nor delete: an identifier attribute and a display name attribute. By default they are named Code and Name, but when creating a reference table you can choose different names — for example ISOCode and CurrencyName. Standard tables start with Code and Name. You can rename either attribute later from Edit Attributes.

  • Identifier — a short, stable business key, for example SEK or 1200.
  • Display name — a readable label, for example Swedish krona.

They exist so that a record can be presented to a human as SEK - Swedish krona. This matters most when the table is used as a reference table.

In the app this is a single switch: Use this as a reference table. Behind the scenes it sets the table’s code generation to MANUAL (the technical name you may see in the API).

Standard table (AUTO) Reference table (MANUAL)
Identifier is supplied by Grunddata unless you enter a Code You
Identifier required on every record No Yes
Display name required on every record No No
Identifier / display name visible in forms and grids Yes Yes
Can be referenced by other tables No Yes
Typical use Data and transactional tables Lookups and reference lists
  1. Go to Models and open the model the table belongs to. If you have no model yet, create one first.

  2. Click Create Table.

  3. Fill in the name and an optional description.

  4. Decide whether this is a reference table. If it is, choose the names for the identifier and display name columns (defaults: Code and Name).

  5. Add any tags, then click Create.

You can also see every table across every model from the top-level Tables page — useful when you know the table name but not which model it is in.

Opening a table gives you its overview page, which is the hub for everything about it:

  • Rows and Attributes — counts linking to the data grid and columns.
  • Records — the data grid, with add, edit and delete.
  • Views — the OData contracts built from this table.
  • Latest Record Commits — the six latest commits, with links to comparisons when a previous commit exists.
  • Edit Table — change name, description and tags.
  • Delete Table — remove the table, when nothing references it.

Administrators can select Show access control to manage the table’s access settings, and hide them again when finished.

From the table overview click Edit Table, or use the pencil icon in a table listing. You can change the name, description and tags.

From the table overview click Delete Table, or use the trash icon in a table listing, and confirm.

Deleting a model soft-deletes all its tables and views together, while retaining the records. The confirmation shows how many tables and views will be affected and lists any external formula or domain-attribute references that must be removed before the model can be deleted.