chore: drop redundant indexes in sqlite migration

This commit is contained in:
Johnny 2026-01-08 22:53:46 +08:00
parent 1985205dc2
commit af6a0726d8
2 changed files with 4 additions and 8 deletions

View File

@ -0,0 +1,4 @@
DROP INDEX IF EXISTS idx_user_username;
DROP INDEX IF EXISTS idx_memo_creator_id;
DROP INDEX IF EXISTS idx_attachment_creator_id;
DROP INDEX IF EXISTS idx_attachment_memo_id;

View File

@ -21,8 +21,6 @@ CREATE TABLE user (
description TEXT NOT NULL DEFAULT ''
);
CREATE INDEX idx_user_username ON user (username);
-- user_setting
CREATE TABLE user_setting (
user_id INTEGER NOT NULL,
@ -45,8 +43,6 @@ CREATE TABLE memo (
payload TEXT NOT NULL DEFAULT '{}'
);
CREATE INDEX idx_memo_creator_id ON memo (creator_id);
-- memo_relation
CREATE TABLE memo_relation (
memo_id INTEGER NOT NULL,
@ -72,10 +68,6 @@ CREATE TABLE attachment (
payload TEXT NOT NULL DEFAULT '{}'
);
CREATE INDEX idx_attachment_creator_id ON attachment (creator_id);
CREATE INDEX idx_attachment_memo_id ON attachment (memo_id);
-- activity
CREATE TABLE activity (
id INTEGER PRIMARY KEY AUTOINCREMENT,