Re: BUG #17094: FailedAssertion at planner.c

Richard Guo <guofenglinux@gmail.com>

From: Richard Guo <guofenglinux@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: cyg0810@gmail.com, PostgreSQL mailing lists <pgsql-bugs@lists.postgresql.org>
Date: 2021-07-09T07:17:41Z
Lists: pgsql-bugs
On Fri, Jul 9, 2021 at 1:22 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:

> I wrote:
> > I'm inclined to think we have to reject cases like this.
>
> Concretely, about like this.  I noticed that the adjacent error
> cases in RewriteQuery were mostly not covered either by the
> regression tests, so I added tests to hit them all.
>

It makes sense to me we reject this case. Tested the patch and it works
as expected.

Thanks
Richard

Commits

  1. Reject cases where a query in WITH rewrites to just NOTIFY.