Re: Possible bug: SQL function parameter in window frame definition

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andrew Gierth <andrew(at)tao11(dot)riddles(dot)org(dot)uk>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Possible bug: SQL function parameter in window frame definition
Date: 2019-10-02 15:32:51
Message-ID: 6666.1570030371@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

Andrew Gierth <andrew(at)tao11(dot)riddles(dot)org(dot)uk> writes:
> "Tom" == Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> writes:
> Tom> Also, in HEAD I'd be inclined to add assertions about utilityStmt
> Tom> being NULL.

> Tried this. The assertion is hit:
> ...

> Any suggestions where best to fix this? transformRuleStmt could be
> taught to skip a lot of the per-Query stuff it does in the event that
> the Query is actually a NOTIFY, or a check for NOTIFY could be added
> further down the stack, e.g. in rangeTableEntry_used. Any preferences?

Hm. transformRuleStmt already does special-case utility statements to
some extent, so my inclination would be to make it do more of that.
However, it looks like that might end up with rather spaghetti-ish
code, as that function is kind of messy already.

Or we could abandon the notion of adding the assertion. I don't
know how much work it's worth.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Jason Ralph 2019-10-02 15:41:00 PG11 Parallel Thanks!!
Previous Message Andrew Gierth 2019-10-02 15:24:05 Re: Possible bug: SQL function parameter in window frame definition

Browse pgsql-hackers by date

  From Date Subject
Next Message Joe Nelson 2019-10-02 15:34:20 Re: Proposal: Make use of C99 designated initialisers for nulls/values arrays
Previous Message Andrew Gierth 2019-10-02 15:24:05 Re: Possible bug: SQL function parameter in window frame definition