Add table for client side extra room metadata

This commit is contained in:
Adam Brown 2023-01-18 21:23:26 +00:00
parent 0abac7c551
commit 8312c20d5d
2 changed files with 23 additions and 0 deletions

View File

@ -0,0 +1,5 @@
CREATE TABLE IF NOT EXISTS dbStRoomMeta (
room_id TEXT NOT NULL,
is_bubble INTEGER AS Int NOT NULL DEFAULT 0,
PRIMARY KEY (room_id)
);

View File

@ -0,0 +1,18 @@
CREATE TABLE dbStRoomMeta (
room_id TEXT NOT NULL,
is_bubble INTEGER AS Int NOT NULL DEFAULT 0,
PRIMARY KEY (room_id)
);
markBubble:
INSERT OR REPLACE INTO dbStRoomMeta(room_id, is_bubble)
VALUES (?,?);
unmarkBubble:
INSERT OR REPLACE INTO dbStRoomMeta(room_id, is_bubble)
VALUES (?,?);
select:
SELECT is_bubble
FROM dbStRoomMeta
WHERE room_id = ?;