Skip to content

Commit

Permalink
fix: remove manual transaction on sqlite migration 2 (go-shiori#468)
Browse files Browse the repository at this point in the history
  • Loading branch information
fmartingr authored Aug 11, 2022
1 parent 0246e10 commit c8fec2a
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
BEGIN TRANSACTION;
ALTER TABLE bookmark DROP COLUMN has_content;
COMMIT;
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
BEGIN TRANSACTION;
ALTER TABLE bookmark
ADD has_content BOOLEAN DEFAULT FALSE NOT NULL;

UPDATE bookmark
SET has_content = bc.has_content FROM (SELECT docid, content <> '' AS has_content FROM bookmark_content) AS bc
WHERE bookmark.id = bc.docid;
COMMIT;

0 comments on commit c8fec2a

Please sign in to comment.