Re: Calling PL functions with named parameters

Поиск
Список
Период
Сортировка
От Josh Berkus
Тема Re: Calling PL functions with named parameters
Дата
Msg-id 200408141246.23569.josh@agliodbs.com
обсуждение исходный текст
Ответ на Calling PL functions with named parameters  (David Fetter <david@fetter.org>)
Ответы Re: Calling PL functions with named parameters  (Peter Eisentraut <peter_e@gmx.net>)
Список pgsql-hackers
David,

> Dennis has pointed out that mixing the call-with-named-parameter
> interface with call-by-order-of-parameters one would cause confusion,
> and I think it would be OK to disallow this type mixing, so

As we've discussed on IRC, this should be the difference between a FUNCTION 
and a PROCEDURE.  It's about time we implemented a CREATE PROCEDURE statement 
anyway.  

As I see it, the critical difference between FUNCTIONS and PROCEDURES can be 
that:
a) Procedures support named parameter calling but do NOT allow being called in 
the context of a query, and
b) Procedures are not automatically transactional; that is, transactions 
within procedures must/can be explicit.  Among other things, this would allow 
procedures to run maintainence tasks.

This seems to me to be the obvious solution to the Named Parameters vs. 
Overloading conflict, and I'm really puzzled why people keep dismissing it as 
out-of-hand.

-- 
Josh Berkus
Aglio Database Solutions
San Francisco


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

Предыдущее
От: ohp@pyrenet.fr
Дата:
Сообщение: 8.0beta1 with unixware
Следующее
От: Christopher Browne
Дата:
Сообщение: Re: Postgres development model