From: | Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com> |
---|---|
To: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
Cc: | pgsql-hackers(at)postgresql(dot)org, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Subject: | Re: Patch for 8.5, transformationHook |
Date: | 2009-04-20 06:52:05 |
Message-ID: | 162867790904192352q24ca8282xe59f608eb7428145@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
2009/4/20 Peter Eisentraut <peter_e(at)gmx(dot)net>:
> On Sunday 19 April 2009 20:47:37 Pavel Stehule wrote:
>> 2009/4/19 Peter Eisentraut <peter_e(at)gmx(dot)net>:
>> > On Saturday 18 April 2009 18:09:00 Pavel Stehule wrote:
>> >> There are lot of things, that should be done with current grammar only
>> >> on transformation stage. Currently pg do it now. There are lot of
>> >> pseudo functions, that are specially transformed: least, greatest,
>> >> coalesce. After hooking we should do some similar work from outer
>> >> libraries.
>> >
>> > There are surely other ways to accomplish this than an expression
>> > transformation hook. Adding a property or two to the function definition
>> > to do what you want could do it.
>>
>> should you describe it little bit more?
>
> The question we should be asking is, what is it that prevents us from
> implementing least, greatest, and coalesce in user space now? And then design
> a solution for that, if we wanted to pursue this. Instead of writing
> transformation hooks and then force every problem to fit that solution.
>
I don't believe so is possible to find other general solution. (or
better I didn't find any other solution). Tom has true,
transformationHook on expression is expensive. I thing, so hook on
function should be simple and fast - not all transformation's should
be simple defined via property - classic sample is "decode" like
functions, it needs procedural code.
regards
Pavel Stehule
From | Date | Subject | |
---|---|---|---|
Next Message | Heikki Linnakangas | 2009-04-20 08:32:23 | Re: Warm Standby restore_command documentation |
Previous Message | KaiGai Kohei | 2009-04-20 06:43:27 | Re: [PATCH] unalias of ACL_SELECT_FOR_UPDATE |