Re: named parameters in SQL functions

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: named parameters in SQL functions
Дата
Msg-id 603c8f070911151735v49c95da1mb6e854e88222ced5@mail.gmail.com
обсуждение исходный текст
Ответ на Re: named parameters in SQL functions  (Andrew Dunstan <andrew@dunslane.net>)
Ответы Re: named parameters in SQL functions
Список pgsql-hackers
On Sun, Nov 15, 2009 at 8:22 PM, Andrew Dunstan <andrew@dunslane.net> wrote:
> Tom Lane wrote:
>>
>> Andrew Dunstan <andrew@dunslane.net> writes:
>>
>>>
>>> At Tom's suggestion I am looking at allowing use of parameter names in
>>> SQL functions instead of requiring use of $1 etc. That raises the question
>>> of how we would disambiguate a parameter name from a column name.
>>>
>>
>> Throw error if ambiguous.  We already resolved this in the context of
>> plpgsql.
>>
>>
>>
>
> Well, if the funcname.varname gadget will work, as you suggest elsewhere it
> could, I think that would suffice. I had assumed that was just something in
> the plpgsql engine.

That gadget isn't horribly convenient for me since my function names
tend to be 30 or 40 characters long.  I wish we had something shorter,
and maybe constant.  But I guess that's a topic for a separate
(inevitably rejected) patch.

...Robert


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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: Patch committers
Следующее
От: James Pye
Дата:
Сообщение: Re: Python 3.1 support