pgsql: Mop-up for letting VOID-returning SQL functions end with aSELEC

Поиск
Список
Период
Сортировка
От Tom Lane
Тема pgsql: Mop-up for letting VOID-returning SQL functions end with aSELEC
Дата
Msg-id E1ewsWp-00035S-P7@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Mop-up for letting VOID-returning SQL functions end with a SELECT.

Part of the intent in commit fd1a421fe was to allow SQL functions that are
declared to return VOID to contain anything, including an unrelated final
SELECT, the same as SQL-language procedures can.  However, the planner's
inlining logic didn't get that memo.  Fix it, and add some regression tests
covering this area, since evidently we had none.

In passing, clean up some typos in comments in create_function_3.sql,
and get rid of its none-too-safe assumption that DROP CASCADE notice
output is immutably ordered.

Per report from Prabhat Sahu.

Discussion: https://postgr.es/m/CANEvxPqxAj6nNHVcaXxpTeEFPmh24Whu+23emgjiuKrhJSct0A@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/877cdf11eaa9cabcb9b1e3c1bef0760fe08efdc3

Modified Files
--------------
src/backend/optimizer/util/clauses.c            | 25 +++++--
src/test/regress/expected/create_function_3.out | 90 +++++++++++++++++++------
src/test/regress/sql/create_function_3.sql      | 48 +++++++++++--
3 files changed, 130 insertions(+), 33 deletions(-)


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

Предыдущее
От: David Steele
Дата:
Сообщение: Re: pgsql: Add tests for reinit.c
Следующее
От: Peter Eisentraut
Дата:
Сообщение: pgsql: Rename TransactionChain functions