pg.ddx.io  pgsql-docs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andres Freund <andres@anarazel.de>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Laurenz Albe <laurenz.albe@cybertec.at>
Cc: suchithjn22@gmail.com
Cc: pgsql-docs@lists.postgresql.org
Subject: Re: The documentation for storage type 'plain' actually allows single byte header
Date: Sun, 15 Jan 2023 15:03:20 -0800
Message-ID: <20230115230320.d3mtlzek6dv7mgxx@awork3.anarazel.de> (raw)
In-Reply-To: <1698750.1673818827@sss.pgh.pa.us>
References: <167336599095.2667301.15497893107226841625@wrigleys.postgresql.org>
	<d99b3e0beebdde0741d28035aaea7f4af56fa050.camel@cybertec.at>
	<1698750.1673818827@sss.pgh.pa.us>

Hi,

On 2023-01-15 16:40:27 -0500, Tom Lane wrote:
> The documentation is correct, what is broken is the code.  I'm not
> sure when we broke it

Looks to be an old issue, predating the slot type stuff. It reproduces at
least as far back as 10.

I've not thought through this fully. But after a first look, this might be
hard to fix without incuring a lot of overhead / complexity. We check whether
projection is needed between nodes with tlist_matches_tupdesc() - targetlists
don't know about storage. And we decide whether we need to project in
nodeModifyTuple solely based on

	/* Extract non-junk columns of the subplan's result tlist. */
	foreach(l, subplan->targetlist)
	{
		TargetEntry *tle = (TargetEntry *) lfirst(l);

		if (!tle->resjunk)
			insertTargetList = lappend(insertTargetList, tle);
		else
			need_projection = true;
	}

Greetings,

Andres Freund





view thread (19+ messages)  latest in thread

Message-ID: <20230115230320.d3mtlzek6dv7mgxx@awork3.anarazel.de>
Permalink:  ../20230115230320.d3mtlzek6dv7mgxx@awork3.anarazel.de/
Also on:    postgresql.org/message-id/20230115230320.d3mtlzek6dv7mgxx@awork3.anarazel.de

 · 

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-docs@postgresql.org
  Cc: andres@anarazel.de, tgl@sss.pgh.pa.us, laurenz.albe@cybertec.at, suchithjn22@gmail.com, pgsql-docs@lists.postgresql.org
  Subject: Re: The documentation for storage type 'plain' actually allows single byte header
  In-Reply-To: <20230115230320.d3mtlzek6dv7mgxx@awork3.anarazel.de>

* 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