Re: WIP: hooking parser

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема Re: WIP: hooking parser
Дата
Msg-id 499532BC.9030407@enterprisedb.com
обсуждение исходный текст
Ответ на Re: WIP: hooking parser  (Peter Eisentraut <peter_e@gmx.net>)
Ответы Re: WIP: hooking parser
Re: WIP: hooking parser
Список pgsql-hackers
Peter Eisentraut wrote:
> Tom Lane wrote:
>> Peter Eisentraut <peter_e@gmx.net> writes:
>>> I think what you want here is some way to define a function that 
>>> takes an arbitrary number of arguments of arbitrary type and let the 
>>> function figure everything out.  I see no reason why this can't be a 
>>> variant on CREATE FUNCTION, except that of course you need to figure 
>>> out some API and function resolution details.
>>
>> We've already got "variadic any" functions --- the problem is to tell
>> the parser what the function's result type will be, given a particular
>> parameter list.  I agree that hooking transformExpr is not exactly the
>> most ideal way to attack that from a performance or complexity
>> standpoint.
> 
> What is the defined return type logic for the decode() function anyway? 
>  If you want the full CASE-like resolution logic, it might be very hard 
> to fit that into a general system.

And on top of that, decode() is supposed to do short-circuit evaluation 
of the arguments.

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


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

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: WIP: hooking parser
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: pg_migrator and handling dropped columns