pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: David Rowley <drowley@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Adjust overly strict Assert
Date: Sun, 21 Jul 2019 22:30:13 +0000
Message-ID: <E1hpKLN-0006ke-EG@gemulon.postgresql.org> (raw)

Adjust overly strict Assert

3373c7155 changed how we determine EquivalenceClasses for relations and
added an Assert to ensure all relations mentioned in each EC's ec_relids
was a RELOPT_BASEREL.  However, the join removal code may remove a LEFT
JOIN and since it does not clean up EC members belonging to the removed
relations it can leave RELOPT_DEADREL rels in ec_relids.

Fix this by adjusting the Assert to allow RELOPT_DEADREL rels too.

Reported-by: sqlsmith via Andreas Seltenreich
Discussion: https://postgr.es/m/87y30r8sls.fsf@ansel.ydns.eu

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/e1a0f6a983068675813074847e1d0d61bd37ac0e

Modified Files
--------------
src/backend/optimizer/path/equivclass.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)



Message-ID: <E1hpKLN-0006ke-EG@gemulon.postgresql.org>
Permalink:  ../E1hpKLN-0006ke-EG@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1hpKLN-0006ke-EG@gemulon.postgresql.org

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: drowley@postgresql.org
  Subject: Re: pgsql: Adjust overly strict Assert
  In-Reply-To: <E1hpKLN-0006ke-EG@gemulon.postgresql.org>
  References: <E1hpKLN-0006ke-EG@gemulon.postgresql.org>

* 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