pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Yuzuko Hosoya <hosoya.yuzuko@lab.ntt.co.jp>
To: 'Amit Langote' <Langote_Amit_f8@lab.ntt.co.jp>
To: 'Thibaut Madelaine' <thibaut.madelaine@dalibo.com>
To: 'Imai, Yoshikazu' <imai.yoshikazu@jp.fujitsu.com>
Cc: 'PostgreSQL Hackers' <pgsql-hackers@lists.postgresql.org>
Subject: RE: Problem with default partition pruning
Date: Mon, 25 Mar 2019 11:03:05 +0900
Message-ID: <005801d4e2ae$e29e5080$a7daf180$@lab.ntt.co.jp> (raw)
In-Reply-To: <fa6ba10b-2123-22b6-8888-e6a3ec84101a@lab.ntt.co.jp>
References: <00e601d4ca86$932b8bc0$b982a340$@lab.ntt.co.jp>
	<afef4fb8-c448-d54a-9628-7c26277d4895@lab.ntt.co.jp>
	<010e01d4ce68$c0427b10$40c77130$@lab.ntt.co.jp>
	<0F97FA9ABBDBE54F91744A9B37151A5129A78A@g01jpexmbkw24>
	<a4968068-6401-7a9c-8bd4-6a3bc9164a86@dalibo.com>
	<001901d4daf5$1ef4f640$5cdee2c0$@lab.ntt.co.jp>
	<9bed6b79-f264-6976-b880-e2a5d23e9d85@lab.ntt.co.jp>
	<003501d4de21$8816f540$9844dfc0$@lab.ntt.co.jp>
	<bd03f475-30d4-c4d0-3d7f-d2fbde755971@dalibo.com>
	<9bb31dfe-b0d0-53f3-3ea6-e64b811424cf@lab.ntt.co.jp>
	<c6b9557e-c029-e72c-c697-3f216e559806@dalibo.com>
	<005101d4e074$e24d1e40$a6e75ac0$@lab.ntt.co.jp>
	<001ea23e-638f-9ab2-143d-2cf1105bf8d6@lab.ntt.co.jp>
	<6213e860-c93b-1934-f5d4-bc3f5999e3af@dalibo.com>
	<fa6ba10b-2123-22b6-8888-e6a3ec84101a@lab.ntt.co.jp>

Hi,

> 
> Hi,
> 
> On 2019/03/23 2:36, Thibaut Madelaine wrote:
> > I tested your last patch and if I didn't mix up patches on the end of
> > a too long week, I get a problem when querying the sub-sub partition:
> >
> > test=# explain select * from test2_0_10 where id = 25;
> >                          QUERY PLAN
> > ------------------------------------------------------------
> >  Seq Scan on test2_0_10  (cost=0.00..25.88 rows=6 width=36)
> >    Filter: (id = 25)
> > (2 rows)
> 
> The problem here is not really related to partition pruning, but another problem I recently sent an
> email about:
> 
> https://www.postgresql.org/message-id/9813f079-f16b-61c8-9ab7-4363cab28d80%40lab.ntt.co.jp
> 
> The problem in this case is that *constraint exclusion* is not working, because partition constraint
> is not loaded by the planner.  Note that pruning is only used if a query specifies the parent table,
> not a partition.

Thanks for the comments.

I saw that email.  Also, I checked that query Thibaut mentioned worked
correctly with Amit's patch discussed in that thread.


Best regards,
Yuzuko Hosoya






view thread (89+ messages)  latest in thread

Message-ID: <005801d4e2ae$e29e5080$a7daf180$@lab.ntt.co.jp>
Permalink:  ../005801d4e2ae$e29e5080$a7daf180$@lab.ntt.co.jp/
Also on:    postgresql.org/message-id/005801d4e2ae$e29e5080$a7daf180$@lab.ntt.co.jp

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: hosoya.yuzuko@lab.ntt.co.jp, Langote_Amit_f8@lab.ntt.co.jp, thibaut.madelaine@dalibo.com, imai.yoshikazu@jp.fujitsu.com, pgsql-hackers@lists.postgresql.org
  Subject: RE: Problem with default partition pruning
  In-Reply-To: <005801d4e2ae$e29e5080$a7daf180$@lab.ntt.co.jp>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox