From 0d88c8a3e44e064367514eb1891b3920d97a992e Mon Sep 17 00:00:00 2001 From: Dev-iL <6509619+Dev-iL@users.noreply.github.com> Date: Mon, 9 Feb 2026 19:10:16 +0200 Subject: [PATCH] Include GiST index type in query index types documentation (#33) Added GiST index type for geometric data and nearest-neighbor queries. --- .../references/query-index-types.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/skills/supabase-postgres-best-practices/references/query-index-types.md b/skills/supabase-postgres-best-practices/references/query-index-types.md index 0d7651a..93b3259 100644 --- a/skills/supabase-postgres-best-practices/references/query-index-types.md +++ b/skills/supabase-postgres-best-practices/references/query-index-types.md @@ -2,7 +2,7 @@ title: Choose the Right Index Type for Your Data impact: HIGH impactDescription: 10-100x improvement with correct index type -tags: indexes, btree, gin, brin, hash, index-types +tags: indexes, btree, gin, gist, brin, hash, index-types --- ## Choose the Right Index Type for Your Data @@ -35,6 +35,9 @@ create index users_created_idx on users (created_at); -- GIN: arrays, JSONB, full-text search create index posts_tags_idx on posts using gin (tags); +-- GiST: geometric data, range types, nearest-neighbor (KNN) queries +create index locations_idx on places using gist (location); + -- BRIN: large time-series tables (10-100x smaller) create index events_time_idx on events using brin (created_at);