home / audit

Menu
  • Dashboards

event_enrichments

0 rows where event_id = 39

✎ View and edit SQL

This data as json

0 records

CREATE TABLE event_enrichments (
    event_id            INTEGER PRIMARY KEY REFERENCES events(id) ON DELETE CASCADE,
    enrichment_status   TEXT NOT NULL,         -- 'pending' | 'ok' | 'failed' | 'skipped'
    enrichment_attempts INTEGER NOT NULL DEFAULT 0,
    enrichment_next_at  TEXT,                  -- earliest time to try next, ISO 8601
    enrichment_started  TEXT,                  -- when first enqueued (for SLA tracking)
    enriched_at         TEXT,                  -- when enrichment completed
    enrichment_json     TEXT,                  -- the fetched entity body
    enrichment_error    TEXT                   -- last error message if failed
);
CREATE INDEX idx_enrich_pending
    ON event_enrichments(enrichment_status, enrichment_next_at, event_id)
    WHERE enrichment_status = 'pending';
Powered by Datasette · Queries took 7.901ms