From: Andrew Gierth <andrew@tao11.riddles.org.uk>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #7808: unnest doesn't handle nulls in array of composite typescorrectly
Date: Wed, 27 Jul 2016 04:59:50 +0100
Message-ID: <8737mvn3ag.fsf@news-spur.riddles.org.uk> (raw)
In-Reply-To: <4240.1469583457@sss.pgh.pa.us>
References: <E1TurJE-0006Es-TK@wrigleys.postgresql.org>
<87wpkcpyud.fsf@news-spur.riddles.org.uk>
<18501.1469285358@sss.pgh.pa.us>
<87eg6koste.fsf@news-spur.riddles.org.uk>
<4240.1469583457@sss.pgh.pa.us>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
>>>>> "Tom" == Tom Lane <tgl@sss.pgh.pa.us> writes:
Tom> I didn't much like the "initial_nulls" counter in your patch, but
Tom> actually there's no reason we can't just push an all-nulls row
Tom> into the tuplestore immediately on seeing a null, the same way as
Tom> happens in the last-ditch case at the bottom of
Tom> ExecMakeTableFunctionResult. I whacked that around a bit and
Tom> pushed it.
I did think about that, but the existing code seems to go out of its way
to build the tuplestore using the tupdesc obtained from the actual
function result row, rather than the "expected" tupdesc, and it wasn't
really obvious why that was.
--
Andrew (irc:RhodiumToad)
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
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-bugs@postgresql.org
Cc: andrew@tao11.riddles.org.uk, tgl@sss.pgh.pa.us
Subject: Re: BUG #7808: unnest doesn't handle nulls in array of composite typescorrectly
In-Reply-To: <8737mvn3ag.fsf@news-spur.riddles.org.uk>
References: <E1TurJE-0006Es-TK@wrigleys.postgresql.org> <87wpkcpyud.fsf@news-spur.riddles.org.uk> <18501.1469285358@sss.pgh.pa.us> <87eg6koste.fsf@news-spur.riddles.org.uk> <4240.1469583457@sss.pgh.pa.us> <8737mvn3ag.fsf@news-spur.riddles.org.uk>
* 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