Indexes & Primary Keys (based on the same columns)

From: Ow Mun Heng <Ow(dot)Mun(dot)Heng(at)wdc(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Indexes & Primary Keys (based on the same columns)
Date: 2007-10-22 03:44:14
Message-ID: 1193024654.1104.26.camel@neuromancer.home.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I'm wondering if what I'm doing is redundant.

I have a primary key on columns (A,B,C,D)
and I've also defined an index based on the same columns (A,B,C,D)

and sometimes in the query explain, I see the pkey being used for the
scan instead of the index.

So.. That made me think perhaps the additional index on the _same_
parameter is redundant.

Appreciate comments.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Joshua D. Drake 2007-10-22 03:49:58 Re: Indexes & Primary Keys (based on the same columns)
Previous Message Ow Mun Heng 2007-10-22 03:42:50 Re: command to view the tables