-- Optional TimescaleDB migration for the acquisition-stage event table.
-- Enable only when the target PostgreSQL instance has TimescaleDB installed.
create extension if not exists timescaledb;

select create_hypertable(
    'eventhub.event',
    'occurred_at',
    if_not_exists => true,
    migrate_data => true
);
