From 13163232ecdbfae3178280db97e75c83adf86ecb Mon Sep 17 00:00:00 2001 From: keyan Date: Sun, 6 Nov 2022 12:31:07 -0600 Subject: [PATCH] update ltree extension --- .../migrations/20220412190704_item_path_index/migration.sql | 2 +- .../migrations/20221106181637_item_path_index/migration.sql | 3 +++ .../migrations/20221106184713_item_path_index/migration.sql | 4 ++++ 3 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 prisma/migrations/20221106181637_item_path_index/migration.sql create mode 100644 prisma/migrations/20221106184713_item_path_index/migration.sql diff --git a/prisma/migrations/20220412190704_item_path_index/migration.sql b/prisma/migrations/20220412190704_item_path_index/migration.sql index f701cd03..2ec14089 100644 --- a/prisma/migrations/20220412190704_item_path_index/migration.sql +++ b/prisma/migrations/20220412190704_item_path_index/migration.sql @@ -1 +1 @@ -CREATE INDEX IF NOT EXISTS "item_gist_path_index" ON "Item" USING GIST ("path"); \ No newline at end of file +CREATE INDEX "item_gist_path_index" ON "Item" USING GIST ("path" gist_ltree_ops(siglen=2024)); \ No newline at end of file diff --git a/prisma/migrations/20221106181637_item_path_index/migration.sql b/prisma/migrations/20221106181637_item_path_index/migration.sql new file mode 100644 index 00000000..5dff7dd6 --- /dev/null +++ b/prisma/migrations/20221106181637_item_path_index/migration.sql @@ -0,0 +1,3 @@ +-- This is an empty migration. +DROP INDEX "Item.path_index"; +CREATE INDEX "Item.path_index" ON "Item" USING GIST ("path" gist_ltree_ops(siglen=2024)); diff --git a/prisma/migrations/20221106184713_item_path_index/migration.sql b/prisma/migrations/20221106184713_item_path_index/migration.sql new file mode 100644 index 00000000..56ebbe27 --- /dev/null +++ b/prisma/migrations/20221106184713_item_path_index/migration.sql @@ -0,0 +1,4 @@ +-- This is an empty migration. +ALTER EXTENSION ltree UPDATE TO '1.2'; +DROP INDEX "Item.path_index"; +CREATE INDEX "Item.path_index" ON "Item" USING GIST ("path" gist_ltree_ops(siglen=2024)); \ No newline at end of file