From: | Andres Freund <andres(at)anarazel(dot)de> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Chapman Flack <chap(at)anastigmatix(dot)net>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: checking my understanding of TupleDesc |
Date: | 2019-11-12 23:13:02 |
Message-ID: | 20191112231302.jzed2hzqnb7rgxgh@alap3.anarazel.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
On 2019-11-12 17:39:20 -0500, Tom Lane wrote:
> > and under what other
> > circumstances one would only encounter 'cleaned up' TupleDescs with
> > no dropped attributes, and contiguous numbers for the real ones?
>
> I don't believe we ever include dropped columns in a projection result,
> so generally speaking, the output of a query plan node wouldn't have them.
>
> There's a semi-exception, which is that the planner might decide that we
> can skip a projection step for the output of a table scan node, in which
> case dropped columns would be included in its output. But that would only
> be true if there are upper plan nodes that are doing some projections of
> their own. The final query output will definitely not have them.
I *think* we don't even do that, because build_physical_tlist() bails
out if there's a dropped (or missing) column. Or are you thinking of
something else?
Greetings,
Andres Freund
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2019-11-12 23:15:28 | Re: make pg_attribute_noreturn() work for msvc? |
Previous Message | Andres Freund | 2019-11-12 23:08:35 | Re: make pg_attribute_noreturn() work for msvc? |