Re: Incorrect comment in get_partition_dispatch_recurse

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Amit Langote <amitlangote09(at)gmail(dot)com>
Cc: David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>
Subject: Re: Incorrect comment in get_partition_dispatch_recurse
Date: 2018-05-17 18:21:18
Message-ID: CA+TgmobAq+mA5hzm0a5OS38qQY5758DDDGqa3sBJN4hvir-H9w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, May 17, 2018 at 10:36 AM, Amit Langote <amitlangote09(at)gmail(dot)com> wrote:
> On Thu, May 17, 2018 at 10:29 PM, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
>> Unless the indexing system actually can't reference the first element
>> of *pds, and -1 means the second element. But then I think we need a
>> more verbose explanation here.
>
> First element in *pds list (and the array subsequently created from
> it) contains the root table's entry. So, a -1 does mean the 2nd entry
> in that list/array. A 0 in the indexes array always refers to a leaf
> partition and hence an index into the array for leaf partitions.

All right, so let's just say that explicitly. Maybe something like
the attached.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Attachment Content-Type Size
another-try.patch application/octet-stream 1.4 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2018-05-17 18:23:00 Re: Postgres 11 release notes
Previous Message Robert Haas 2018-05-17 18:15:40 Re: Postgres, fsync, and OSs (specifically linux)