mirror of
https://github.com/dfpc-coe/CloudTAK.git
synced 2025-12-22 05:37:16 +00:00
Improve Migration
This commit is contained in:
@@ -1 +1,8 @@
|
||||
ALTER TABLE "icons" ADD COLUMN "format" text NOT NULL;
|
||||
ALTER TABLE "icons" ADD COLUMN "format" text;
|
||||
|
||||
UPDATE "icons"
|
||||
SET
|
||||
"format" = substring("name" from '\.[^.]+$'),
|
||||
"name" = regexp_replace("name", '\.[^.]+$', '');
|
||||
|
||||
ALTER TABLE "icons" ALTER COLUMN "format" SET NOT NULL;
|
||||
Reference in New Issue
Block a user