Re: Composite keys

From: Claudio Freire <klaussfreire(at)gmail(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Carlo Stonebanks <stonec(dot)register(at)sympatico(dot)ca>, pgsql-performance(at)postgresql(dot)org
Subject: Re: Composite keys
Date: 2011-10-31 17:52:14
Message-ID: CAGTBQpb1E7jQBn1S-yBCMo2w=V+iQRed-sDqNTj=cKPnYRicRg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Mon, Oct 31, 2011 at 2:08 PM, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
>> Multicolumn indices on (c1, c2, ..., cn) can only be used on where
>> clauses involving c1..ck with k<n.
>
> I don't think that's true.  I believe it can be used for a query that
> only touches, say, c2.  It's just extremely inefficient.

Does postgres generate those kinds of plans?
I do not think so. I've never seen it happening.

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Robert Haas 2011-10-31 18:19:18 Re: does update of column with no relation imply a relation check of other column?
Previous Message Robert Haas 2011-10-31 17:08:11 Re: Composite keys