summaryrefslogtreecommitdiff
path: root/migrations/20250819.php
diff options
context:
space:
mode:
Diffstat (limited to 'migrations/20250819.php')
-rw-r--r--migrations/20250819.php21
1 files changed, 21 insertions, 0 deletions
diff --git a/migrations/20250819.php b/migrations/20250819.php
index 5e4eaa4..a0cfd19 100644
--- a/migrations/20250819.php
+++ b/migrations/20250819.php
@@ -54,3 +54,24 @@ Database::getInstance()->query(<<<SQL
"name" varchar(255) not null
);
SQL);
+
+Database::getInstance()->query(<<<SQL
+ create table if not exists "room_events" (
+ "id" varchar(255) primary key,
+
+ "type" varchar(255) not null,
+ "sender" varchar(255) not null,
+
+ "origin_server_timestamp" timestamptz(3) not null,
+
+ "data" json,
+ "content" json,
+ "unsigned" json,
+
+ "previous_event_id" varchar(255),
+ "room_id" varchar(255) not null,
+
+ foreign key (previous_event_id) references room_events(id),
+ foreign key (room_id) references rooms(id)
+ );
+SQL);