ddl_historization

Historize the ddl changes inside PostgreSQL database

Overview

PackageVersionCategoryLicenseLanguage
ddl_historization0.2UTILGPL-2.0SQL
IDExtensionBinLibLoadCreateTrustRelocSchema
4310ddl_historizationNoNoNoYesNoNo-
Relatedplpgsql pgmemento table_log data_historization table_version pgaudit periods temporal_tables emaj provsql pgmnemo
Depended Byschedoc

Version

TypeRepoVersionPG VerPackageDeps
EXTPIGSTY0.21817161514ddl_historizationplpgsql
RPMPIGSTY0.21817161514ddl_historization_$v-
DEBPIGSTY0.21817161514postgresql-$v-ddl-historization-
OS / PGPG18PG17PG16PG15PG14
el8.x86_64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
el8.aarch64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
el9.x86_64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
el9.aarch64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
el10.x86_64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
el10.aarch64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
d12.x86_64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
d12.aarch64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
d13.x86_64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
d13.aarch64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
u22.x86_64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
u22.aarch64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
u24.x86_64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
u24.aarch64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
u26.x86_64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
u26.aarch64
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2
PIGSTY 0.2

Build

You can build the RPM / DEB packages for ddl_historization using pig build:

pig build pkg ddl_historization         # build RPM / DEB packages

Install

You can install ddl_historization directly. First, make sure the PGDG and PIGSTY repositories are added and enabled:

pig repo add pgsql -u          # Add repo and update cache

Install the extension using pig or apt/yum/dnf:

pig install ddl_historization;          # Install for current active PG version
pig ext install -y ddl_historization -v 18  # PG 18
pig ext install -y ddl_historization -v 17  # PG 17
pig ext install -y ddl_historization -v 16  # PG 16
pig ext install -y ddl_historization -v 15  # PG 15
pig ext install -y ddl_historization -v 14  # PG 14
dnf install -y ddl_historization_18       # PG 18
dnf install -y ddl_historization_17       # PG 17
dnf install -y ddl_historization_16       # PG 16
dnf install -y ddl_historization_15       # PG 15
dnf install -y ddl_historization_14       # PG 14
apt install -y postgresql-18-ddl-historization   # PG 18
apt install -y postgresql-17-ddl-historization   # PG 17
apt install -y postgresql-16-ddl-historization   # PG 16
apt install -y postgresql-15-ddl-historization   # PG 15
apt install -y postgresql-14-ddl-historization   # PG 14

Create Extension:

CREATE EXTENSION ddl_historization CASCADE;  -- requires: plpgsql

Usage

Sources: README, releases

ddl_historization is a PostgreSQL extension that records database DDL changes in a historization table. The upstream README documents installation via make install, pgxn install ddl_historization, and an AWS RDS path via pg_tle.

Enable logging

CREATE EXTENSION ddl_historization;

The README describes the extension as using PostgreSQL event triggers to historize DDL changes made in the database.

What upstream currently documents

  • Cluster-local install: make install
  • PGXN install: pgxn install ddl_historization
  • AWS RDS / pg_tle: build pgtle.ddl_historization-0.3.sql with make pgtle
  • Test suite: make test with pgTAP

Release notes worth knowing

  • Release 0.2 is the version requested by this refresh task.
  • Release 0.0.4 says it added functions to start and stop logging.
  • Release 0.0.6 says it added a ddl_history_column table.
  • Release 0.0.7 says it fixed a foreign-key related logging bug.

Caveat

The current upstream README is minimal and does not document the exact SQL signatures for the start/stop logging functions or the schema of the historization tables added in later releases. Keep this stub conservative unless the upstream README or release notes become more explicit.


Last Modified: 2026-07-30: extension update 2026-07-30 (7219c44)