openreplay/ee/scripts/schema/db/init_dbs/clickhouse/1.14.0/1.14.0.sql
Kraiem Taha Yassine 8226e66299
Api v1.14.0 (#1391)
* refactored(chalice): refactored restore user
refactored(chalice): refactored add user

* fix(chalice): allow FastAPI to handel async automatically
fix(chalice): EE support of multiworkers
refactor(chalice): cleaned SSO

* fix(chalice): allow FastAPI to handel async automatically

* feat(DB): associate sessions to feature-flags

* feat(DB): CH associate sessions to feature-flags
2023-07-06 18:13:06 +02:00

15 lines
No EOL
519 B
SQL

CREATE OR REPLACE FUNCTION openreplay_version AS() -> 'v1.14.0-ee';
CREATE TABLE IF NOT EXISTS experimental.sessions_feature_flags
(
session_id UInt64,
project_id UInt16,
feature_flag_id UInt16,
condition_id UInt16,
datetime DateTime,
_timestamp DateTime DEFAULT now()
) ENGINE = ReplacingMergeTree(_timestamp)
PARTITION BY toYYYYMM(datetime)
ORDER BY (project_id, datetime, session_id, feature_flag_id, condition_id)
TTL datetime + INTERVAL 3 MONTH;