Skip to content
This repository was archived by the owner on Mar 23, 2025. It is now read-only.

Commit bd81c2e

Browse files
committed
Fix incorrect migration SQL
1 parent b471ed2 commit bd81c2e

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

migration/titles.5.cr

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,7 @@ class CreateTitles < MG::Base
4242
def down : String
4343
<<-SQL
4444
-- insert the is_title column
45-
ALTER TABLE ids ADD COLUMN is_title INTEGER NOT NULL;
46-
47-
-- set is_title for all rows to 0
48-
UPDATE ids SET column = 0;
45+
ALTER TABLE ids ADD COLUMN is_title INTEGER NOT NULL DEFAULT 0;
4946
5047
-- migrate data from titles to ids
5148
INSERT INTO ids

0 commit comments

Comments
 (0)