pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Richard Guo <guofenglinux@gmail.com>
Cc: Jeff Janes <jeff.janes@gmail.com>
Cc: sindysenorita@gmail.com
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #17618: unnecessary filter column <> text even after adding index
Date: Sat, 05 Nov 2022 13:07:44 -0400
Message-ID: <2616649.1667668064@sss.pgh.pa.us> (raw)
In-Reply-To: <CAMbWs49oBk4EfHC+44xkuAwQYnGH5pyKP40=FwZv9Zecx9=3Mg@mail.gmail.com>
References: <17618-7a2240bfaa7e84ae@postgresql.org>
	<349136.1663601052@sss.pgh.pa.us>
	<CAMkU=1wqvsMwnQTrQ0zoRo2AkYhuEY-RuzpaXrvz7iNu38CVqg@mail.gmail.com>
	<739953.1663701274@sss.pgh.pa.us>
	<946195.1663718159@sss.pgh.pa.us>
	<CAMbWs4-o-VLk3gXqz7W7ZS384S5mvW5noB8f_BKzU_c77DBjXg@mail.gmail.com>
	<2100290.1663942209@sss.pgh.pa.us>
	<CAMbWs4-5CtCGx_nbzfPFTtDCXjmtCOR3vb-OfK4eNEAKwLQPSQ@mail.gmail.com>
	<2174559.1663977891@sss.pgh.pa.us>
	<CAMbWs498iR-5gVbsS0DCmoeK4YNs0nny6xmW-eLvm=C-KXm-Ag@mail.gmail.com>
	<CAMbWs4_AmLq9ssUh+fu8KZk8QPhx21=+o3whspLNAhxY6T0Xzw@mail.gmail.com>
	<CAMbWs49oBk4EfHC+44xkuAwQYnGH5pyKP40=FwZv9Zecx9=3Mg@mail.gmail.com>

Richard Guo <guofenglinux@gmail.com> writes:
> Update with v3 patch, nothing changes except fixes a test failure
> spotted by cfbot.

I think this is pretty close to usable, except that I don't believe
reusing simplify_boolean_equality this way is a great idea.
It does more than we need (surely the LHS-is-Const case cannot occur here)
and it has assumptions that I'm not sure hold --- particularly the bit
about !constisnull.  I'd be inclined to just copy-and-paste the three or
four lines we need.

			regards, tom lane





view thread (21+ messages)  latest in thread

Message-ID: <2616649.1667668064@sss.pgh.pa.us>
Permalink:  ../2616649.1667668064@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/2616649.1667668064@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-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, guofenglinux@gmail.com, jeff.janes@gmail.com, sindysenorita@gmail.com, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #17618: unnecessary filter column <> text even after adding index
  In-Reply-To: <2616649.1667668064@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