Re: TRAP: FailedAssertion("!(hassrf)", File: "nodeProjectSet.c", Line: 180)

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andres Freund <andres@anarazel.de>
Cc: Erik Rijkers <er@xs4all.nl>, Pgsql Hackers <pgsql-hackers@postgresql.org>
Date: 2017-02-02T03:32:52Z
Lists: pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> On 2017-02-02 00:09:03 +0100, Erik Rijkers wrote:
>> Something is broken in HEAD:

> Hm. Indeed.

> The issue is that we're generating ProjectSet nodes instead of Result
> for the top-level nodes - but we currently assume that ProjectSet nodes
> actually contain sets.   I'm tentatively in favor of generating proper
> Result nodes in this case, rather than allowing this in ProjectSet - on
> the other hand, it works after removing that Assert().

> Tom, do you have an opinion?

Yes, it's broken.  split_pathtarget_at_srfs seems to be doing the right
thing, but then something later is recombining the last two steps.
I should be able to find it soon.

Does it really work without the Assert?  I'd think you'd get srf-
where-not-supported errors if the SRF isn't at top level.

			regards, tom lane


Commits

  1. Fix mishandling of tSRFs at different nesting levels.