What type of index should I use?

From: Mike Christensen <mike(at)kitchenpc(dot)com>
To: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: What type of index should I use?
Date: 2010-06-21 09:01:32
Message-ID: AANLkTikfnaVSxYnhCnacMAuTPmQSVHnayaHiDt5j9a_Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I have a varying(200) text column that I need to be able to do lookups
on very fast (WHERE col = 'foo') - The data in this table will pretty
much never change (when it does I have to restart the entire server,
so updates of any sort are extremely rare). I estimate the table will
hold around 5,000 rows, never any more.

Am I better off using a btree index or should I use GiN? From what
I've read, GiN is extremely fast, but very slow for updates. However,
it was unclear to me if they're only fast when doing fulltext
searches, or if they're just fast period.

Thanks!

Mike

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Teodor Macicas 2010-06-21 11:08:24 Re: Inserting additional data into pg_statistics
Previous Message Yaroslav Tykhiy 2010-06-21 02:29:13 Re: High Availability with Postgres