Add date details migrations
This commit is contained in:
parent
9914df7925
commit
c30ffda338
4
migrations/007.date-details.down.sql
Normal file
4
migrations/007.date-details.down.sql
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
-- Remove source details and links
|
||||||
|
|
||||||
|
ALTER TABLE buildings DROP COLUMN IF EXISTS date_source_detail;
|
||||||
|
ALTER TABLE buildings DROP COLUMN IF EXISTS date_link;
|
10
migrations/007.date-details.up.sql
Normal file
10
migrations/007.date-details.up.sql
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
--
|
||||||
|
-- Source details and links
|
||||||
|
--
|
||||||
|
|
||||||
|
-- Create date source details
|
||||||
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS date_source_detail varchar;
|
||||||
|
ALTER TABLE buildings ADD CONSTRAINT buildings_date_source_detail_len CHECK (length(date_source_detail) < 500);
|
||||||
|
|
||||||
|
-- Create list of links
|
||||||
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS date_link text[];
|
Loading…
Reference in New Issue
Block a user