migrations: Add 5.sql: Tag support

This commit is contained in:
Albert S. 2023-04-02 21:37:30 +02:00
parent 07630c3b36
commit a0b95479e2
2 changed files with 7 additions and 0 deletions

6
shared/migrations/5.sql Normal file
View File

@ -0,0 +1,6 @@
CREATE TABLE tag(id integer PRIMARY KEY, name varchar(128) UNIQUE);
CREATE TABLE filetag(fileid integer, tagid integer);
CREATE INDEX filetag_fileid ON filetag(fileid);
CREATE INDEX tag_id ON tag(id);
CREATE INDEX file_path ON file ( path );
UPDATE file SET filetype='c' WHERE filetype='f';

View File

@ -4,5 +4,6 @@
<file>2.sql</file>
<file>3.sql</file>
<file>4.sql</file>
<file>5.sql</file>
</qresource>
</RCC>