feat: Migrationen für campaigns-Tabellen (PostgreSQL) und email_events (ClickHouse)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
11
migrations/ch/2026-04-17_email_events.sql
Normal file
11
migrations/ch/2026-04-17_email_events.sql
Normal file
@@ -0,0 +1,11 @@
|
||||
CREATE TABLE IF NOT EXISTS newsletter.email_events (
|
||||
event_type LowCardinality(String),
|
||||
tenant_id String,
|
||||
campaign_id UUID,
|
||||
recipient_hash String,
|
||||
timestamp DateTime64(3, 'UTC'),
|
||||
metadata Map(String, String)
|
||||
)
|
||||
ENGINE = MergeTree()
|
||||
PARTITION BY toYYYYMM(timestamp)
|
||||
ORDER BY (tenant_id, campaign_id, event_type, timestamp);
|
||||
Reference in New Issue
Block a user