doc: explain how to use functional indexes in migrations (#4149)

This commit is contained in:
Ariel Mashraki
2024-07-20 11:48:52 +03:00
committed by GitHub
parent 807b4a758b
commit 10de04eeaa
28 changed files with 3522 additions and 0 deletions

View File

@@ -0,0 +1,4 @@
-- Create "users" table
CREATE TABLE "users" ("id" bigint NOT NULL GENERATED BY DEFAULT AS IDENTITY, "name" character varying NOT NULL, PRIMARY KEY ("id"));
-- Create index "unique_name" to table: "users"
CREATE UNIQUE INDEX "unique_name" ON "users" ((lower((name)::text)));