Re: Use unique index for longer pathkeys.

From: Kyotaro HORIGUCHI <horiguchi(dot)kyotaro(at)lab(dot)ntt(dot)co(dot)jp>
To: amit(dot)kapila16(at)gmail(dot)com
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Use unique index for longer pathkeys.
Date: 2014-07-15 08:47:48
Message-ID: 20140715.174748.227122637.horiguchi.kyotaro@lab.ntt.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi, the attached is the revised version.

- defined allnotnull instead of full_ordered in RelOptInfo and
changed to use it.

- compare_pathkeys_ignoring_strategy() is now integrated into
compare_pathkeys().

- index pathkeys caching in RelOptInfo
added. (build_index_pathkeys() does)

- Refactoring collect_common_primary_pathkeys mainly from a
reason of eliminating code duplicates and readability.

- trim_query_pathkeys now tries to trim window_pathkeys. The old
comment came from my misunderstanding. Window pathkeys are not
always RowExpr and RowExpr pathkeys are feedable from not only
PARTITION BY clause but also ORDER BY, DISTINCT or GROUP BY
clauses. The comment for the function is modified.

- Some cosmetic fixes including spacing after commas.

- The shortcut judgement is *not* included.

regards,

--
Kyotaro Horiguchi
NTT Open Source Software Center

Attachment Content-Type Size
pathkey_and_uniqueindx_typ2_v2.patch text/x-patch 17.4 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fujii Masao 2014-07-15 09:29:07 Re: psql: show only failed queries
Previous Message Dilip kumar 2014-07-15 03:53:08 Re: Selectivity estimation for inet operators