pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: David Rowley <david.rowley@2ndquadrant.com>
Cc: Mark Dilger <hornschnorter@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Subject: Re: "SELECT ... FROM DUAL" is not quite as silly as it appears
Date: Fri, 04 Jan 2019 16:22:17 -0500
Message-ID: <25353.1546636937@sss.pgh.pa.us> (raw)
In-Reply-To: <20472.1546631337@sss.pgh.pa.us>
References: <15944.1521127664@sss.pgh.pa.us>
	<9565.1539573909@sss.pgh.pa.us>
	<154342395130.2093.8013327151440360209.pgcf@coridan.postgresql.org>
	<12357.1543518669@sss.pgh.pa.us>
	<CAKJS1f-ZRNnb7-NxY1odPR=ZjEiJx=_094aQZsEvJ6JEnzDjKg@mail.gmail.com>
	<20472.1546631337@sss.pgh.pa.us>

I wrote:
> If you reverse out just that change you'll see why I added it: without it,
> the plan for the earlier "test a corner case in which we shouldn't apply
> the star-schema optimization" isn't optimized as much as I thought it
> should be.

Hmm ... looking at this closer, it seems like this patch probably breaks
what that regression test case was actually meant to test, ie once we've
deleted the VALUES subselects from the jointree, it's likely that the
planner join-ordering mistake that was testing for can no longer happen,
because the join just plain doesn't exist.

I'll plan to deal with that by running the test case with actual small
tables instead of VALUES subselects.  It might be useful to run the test
case in its current form as an exercise for the RTE_RESULT optimizations,
but that would be separate from its current intention.

			regards, tom lane




view thread (33+ messages)  latest in thread

Message-ID: <25353.1546636937@sss.pgh.pa.us>
Permalink:  ../25353.1546636937@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/25353.1546636937@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-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, david.rowley@2ndquadrant.com, hornschnorter@gmail.com, pgsql-hackers@lists.postgresql.org
  Subject: Re: "SELECT ... FROM DUAL" is not quite as silly as it appears
  In-Reply-To: <25353.1546636937@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