Re: logical column order and physical column order

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: logical column order and physical column order
Дата
Msg-id 20131105142201.GG5809@eldon.alvh.no-ip.org
обсуждение исходный текст
Ответ на Re: logical column order and physical column order  (David Rowley <dgrowleyml@gmail.com>)
Список pgsql-hackers
David Rowley escribió:

> In this case how does Postgresql know that attnum 3 is the 2nd user column
> in that table? Unless I have misunderstood something then there must be
> some logic in there to skip dropped columns and if so then could it not
> just grab the "attphynum" at that location? then just modify the 1-5 places
> listed above to sort on attlognum?

During parse analysis, those columns obtained from pg_attribute are
transformed to target list entries; they travel through the parser and
executor in that representation, and TupleDescs are constructed from
those lists.  Making that works correctly needs some more code than just
sorting on attlognum.  There are some other messy parts like handling
composite types when passed to functions, COPY, and some other things I
don't remember.  Did you look at the places my patch touches?

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services



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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: [PATCH] configure: add git describe output to PG_VERSION when building a git tree
Следующее
От: Leonardo Francalanci
Дата:
Сообщение: Re: Fast insertion indexes: why no developments