Skip to content

Tables in the PFS Target Database

Overview

The PFS Target Database contains the following tables:

Default values

The values in the "Default" column of each table are applied in two places:

  • The CLI tool and TargetDB.insert() fill them in before inserting. A column missing from the input gets its default, and the CLI also replaces blank cells (empty strings, NaN, masked values) with it.
  • Except for the "" defaults, they are also the database's own column defaults. An INSERT that does not mention a column, from psql or any other client, stores the default. An INSERT that sends NULL explicitly stores NULL.

"" defaults are stored as NULL when inserted through the CLI tool.

Schema information by tbls

You can also look at the schema information generated by the tbls package in the tbls section. They also contain the entity-relationship diagram (ERD) of the database.