pgsql: Transform ALTER TABLE/SET TYPE/USING expr during parse analysis

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема pgsql: Transform ALTER TABLE/SET TYPE/USING expr during parse analysis
Дата
Msg-id E1Ye8LK-0004gH-2N@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Transform ALTER TABLE/SET TYPE/USING expr during parse analysis

This lets later stages have access to the transformed expression; in
particular it allows DDL-deparsing code during event triggers to pass
the transformed expression to ruleutils.c, so that the complete command
can be deparsed.

This shuffles the timing of the transform calls a bit: previously,
nothing was transformed during parse analysis, and only the
RELKIND_RELATION case was being handled during execution.  After this
patch, all expressions are transformed during parse analysis (including
those for relkinds other than RELATION), and the error for other
relation kinds is thrown only during execution.  So we do more work than
before to reject some bogus cases.  That seems acceptable.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/9550e8348b7965715789089555bb5a3fda8c269c

Modified Files
--------------
src/backend/commands/tablecmds.c   |   35 +++++++------------------------
src/backend/parser/parse_utilcmd.c |   40 +++++++++++++++++++++++++++++++++---
2 files changed, 44 insertions(+), 31 deletions(-)


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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: pgsql: Add log_min_autovacuum_duration per-table option
Следующее
От: Tom Lane
Дата:
Сообщение: pgsql: Remove unnecessary variables in _hash_splitbucket().