-
-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
create a table to store bad and new geoms (#2046)
* feat: create geometrylog table to store bad and new geoms * feat: add geometrylog migration in fmtm base schema
- Loading branch information
Showing
7 changed files
with
163 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
-- ## Migration to create a table to store new and bad geometries. | ||
|
||
-- Start a transaction | ||
|
||
BEGIN; | ||
|
||
CREATE TABLE geometrylog ( | ||
id SERIAL PRIMARY KEY, | ||
geom GEOMETRY NOT NULL, | ||
status geomstatus, | ||
project_id int, | ||
task_id int | ||
); | ||
|
||
ALTER TABLE geometrylog OWNER TO fmtm; | ||
|
||
-- Indexes for efficient querying | ||
CREATE INDEX idx_geometrylog ON geometrylog USING gist (geom); | ||
|
||
-- Commit the transaction | ||
COMMIT; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
-- ## Migration to delete geometrylog table. | ||
|
||
-- Start a transaction | ||
|
||
BEGIN; | ||
|
||
DROP TABLE IF EXISTS geometrylog; | ||
|
||
-- Commit the transaction | ||
|
||
COMMIT; |