Re: Fwd: What do these terms mean in the SOURCE CODE?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Fwd: What do these terms mean in the SOURCE CODE?
Дата
Msg-id 3926.1290286299@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Fwd: What do these terms mean in the SOURCE CODE?  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: Fwd: What do these terms mean in the SOURCE CODE?  (Dimitri Fontaine <dimitri@2ndQuadrant.fr>)
Re: Fwd: What do these terms mean in the SOURCE CODE?  (Leonardo Francalanci <m_lists@yahoo.it>)
Список pgsql-hackers
Some additional comments ...

Robert Haas <robertmhaas@gmail.com> writes:
> With regards to your question, for each type of plan node, there is an
> associated "plan state" node.  This is an important distinction
> because, IIUC, plans can be reused, so plan state contains the
> information that might need to be reset on each run.

Yeah.  The plan tree is supposed to be read-only so far as the executor
is concerned, so it needs a parallel "plan state" tree to hold its
runtime state.

> I believe a tuple projection
> is what you get when you do something like SELECT
> generate_series(1,10) FROM tbl - the set-returning function has to be
> "projected" in multiple tuples.

I think "projection" is a term out of relational theory, referring to
any sort of tuple-by-tuple manipulation of the data.  For instance,
if you have a row "a, b, c" and you compute "a, c+1" based on that,
that's a projection.  ExecProject() does this in the general case.
The business with SRFs in a targetlist possibly producing multiple
rows is a PostQUEL-ism that doesn't have any standard technical name
that I know of.

> A qual is a filter condition, e.g. in SELECT * FROM tbl WHERE
> x = 1, the "x = 1" part is a qual.

qual = qualifier.  We use that term with various shades of meaning;
notably an indexqual is a qualifier that is useful for searching an
index.  Large parts of the planner also use the term "clause" to mean
about the same thing.

> It's helpful to grep src/include
> for the structures in question;

Here's my single biggest tip for newcomers to the Postgres source:
if you don't use ctags, glimpse, or some other tool that can quickly
show you all references to a given identifier, go out and get one.
It's one of the easiest ways to learn about things.
        regards, tom lane


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: duplicate connection failure messages
Следующее
От: Yeb Havinga
Дата:
Сообщение: Re: Fix for seg picksplit function