Re: Must I create an index for child table if master table have one?

From: Melvin Davidson <melvin6925(at)gmail(dot)com>
To: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: Edmundo Robles <edmundo(at)sw-argos(dot)com>, "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Must I create an index for child table if master table have one?
Date: 2016-11-08 18:46:48
Message-ID: CANu8Fiztk_F3vyDAvuJz-v4G+8sHVPaxbyuP0pR+bVKz1DU7CQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Nov 8, 2016 at 1:33 PM, David G. Johnston <
david(dot)g(dot)johnston(at)gmail(dot)com> wrote:

> On Tue, Nov 8, 2016 at 11:08 AM, Edmundo Robles <edmundo(at)sw-argos(dot)com>
> wrote:
>
>> Hi!
>>
>> i have a simple question, if the master table have an index, must i
>> have create the same index in a child table?
>> what is the best practice for indexes in table partition ?
>>
>
> Indexes are self-contained within the physical table on which they are
> defined. The index on the master contains no rows that are present in the
> child table.
>
> David J.​
>
>
>Indexes are self-contained within the physical table on which they are
defined
*IOW, yes. *

--
*Melvin Davidson*
I reserve the right to fantasize. Whether or not you
wish to share my fantasy is entirely up to you.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Melvin Davidson 2016-11-08 18:51:13 Re: Must I create an index for child table if master table have one?
Previous Message David G. Johnston 2016-11-08 18:33:02 Re: Must I create an index for child table if master table have one?