Skip to main content

Database

Infra extensions on the entity model. Base: crm-reference.aip. Spec: Specification.

Supported databases (v0.1)

PostgreSQL: aip emit sql. MySQL: declare database mysql and run aip emit mysql (see examples/mysql-minimal.aip). Matrix: Specification § Transpiler matrix.

Migrations

Generated from entity with implicit fields in DDL.

seed


Indexes and constraints


Naming

Rules: lowercase, snake_case, plural table names.

UUID and audit

  • id: uuid by default
  • timestamps: created_at, updated_at
  • soft_delete: nullable deleted_at

Semantic types → PostgreSQL


Flow