mirror of
https://github.com/msfjarvis/compose-lobsters
synced 2025-08-15 18:07:03 +05:30
feat(database): add a table for post comments
This commit is contained in:
parent
3e2d32e4c9
commit
1ae0cbb95d
7 changed files with 77 additions and 27 deletions
Binary file not shown.
|
@ -0,0 +1,17 @@
|
|||
import kotlin.String;
|
||||
import kotlin.collections.List;
|
||||
|
||||
CREATE TABLE IF NOT EXISTS PostComments(
|
||||
postId TEXT NOT NULL PRIMARY KEY,
|
||||
commentIds TEXT AS List<String> NOT NULL
|
||||
);
|
||||
|
||||
rememberComments:
|
||||
INSERT OR REPLACE
|
||||
INTO PostComments
|
||||
VALUES ?;
|
||||
|
||||
getCommentIds:
|
||||
SELECT *
|
||||
FROM PostComments
|
||||
WHERE postId = ?;
|
Loading…
Add table
Add a link
Reference in a new issue