pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Mariel Cherkassky <mariel.cherkassky@gmail.com>
Cc: Andreas Kretschmer <andreas@a-kretschmer.de>
Cc: pgsql-performance@lists.postgresql.org
Subject: Re: postgresql 10.1 wrong plan in when using partitions bug
Date: Sun, 04 Feb 2018 10:39:11 -0500
Message-ID: <15592.1517758751@sss.pgh.pa.us> (raw)
In-Reply-To: <CA+t6e1niwYE_F-fpnwFfZNy-Qk9-2RJT5P4F4UTJatLG2iseVg@mail.gmail.com>
References: <CA+t6e1m54jrEj7spf9ArH5BJiO-Qznn=_YCRGWWMtohvXg7mEg@mail.gmail.com>
	<f042e9cb-be4b-4215-4165-8a14313cbdf7@2ndquadrant.com>
	<CA+t6e1mt-fkvZZX5Wx8B1oPrw=DQOZGr3s=xU_ZhEhKEJtJ-Og@mail.gmail.com>
	<fe3a1929-c843-e10a-8580-302c60db4c13@a-kretschmer.de>
	<CA+t6e1niwYE_F-fpnwFfZNy-Qk9-2RJT5P4F4UTJatLG2iseVg@mail.gmail.com>

Mariel Cherkassky <mariel.cherkassky@gmail.com> writes:
> Great, it solved the issue. Seems problematic that the planner do full
> scans on all partitions in the first case isnt it ? Seems like a bug ?

to_date isn't an immutable function (it depends on timezone and possibly
some other GUC settings).  So there's a limited amount that the planner
can do with it.

			regards, tom lane




view thread (19+ messages)  latest in thread

Message-ID: <15592.1517758751@sss.pgh.pa.us>
Permalink:  ../15592.1517758751@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/15592.1517758751@sss.pgh.pa.us

 · 

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-performance@postgresql.org
  Cc: tgl@sss.pgh.pa.us, mariel.cherkassky@gmail.com, andreas@a-kretschmer.de, pgsql-performance@lists.postgresql.org
  Subject: Re: postgresql 10.1 wrong plan in when using partitions bug
  In-Reply-To: <15592.1517758751@sss.pgh.pa.us>

* 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