Word

table

A table of the app: its columns, whose rows they are, and who may read and write them.

Example

TypeScript
export const orders = table('orders', {
  columns: { team: link('teams', { onRemove: 'remove' }), placedBy: link('users'), note: text({ optional: true }), total: number() },
})

Options

OptionMeans
option.table.columnsThe columns of the table, each a type by its name.
option.table.ownerThe column that says whose row it is.
option.table.accessWho may read, add, change and remove rows.
option.table.searchThe columns that text search covers.
option.table.indexesIndexes over several columns.
option.table.uniqueSets of columns whose values together may stand once.
option.table.keepHistoryWhether old versions of rows are kept.
option.table.removedThe columns that were removed on purpose.
option.table.tenantThe link column that says whose data file a row lives in.
option.table.showsMakes the table the engine's own table of what was counted, under the builder's name and read rule.
option.table.plainHolds the table to the plain form.
option.table.wasThe old name of the table, where it was renamed.
option.table.keptKeeps its rows in the writer's memory alone.
option.table.lastsHow long a row lasts after its last write, or after a moment of its own: past it, the row is removed.

Returns

A table that states tenant gives of(tenant) first: every plan and every write of it starts there, as orders.of(input('team')).where({ status: 'open' }).

The definition, with the plans that start at a table (where, get, search, near, count, group, history, and every member of a plan), the writes (add, change, remove) and the triggers (added, changed, removed). Each answers plain data, and nothing is carried out.

See also

topic.words