From: | pasman pasmański <pasman(dot)p(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, pgsql-general <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: New feature: accumulative functions. |
Date: | 2011-09-25 20:43:22 |
Message-ID: | CAOWY8=ZVNqDAm3q_y-GwG5cfeHAZehtM3WKByX8vY1xKHyOtfQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Yes, i wrote this for pleasure and discusion, not for solve a real problem :).
2011/9/25, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>:
> =?ISO-8859-2?Q?pasman_pasma=F1ski?= <pasman(dot)p(at)gmail(dot)com> writes:
>> I found second use case. Look at expression:
>> where left(str,n)='value'
>
>> function left(str,n) increase monotonically for str and n. With this
>> feature it can use index on str.
>
> Can't get excited about that, because that only works in C locale,
> and in C locale you can already get the same result with
> WHERE str LIKE '...%'
>
> Also, I think you just moved the goalposts quite a bit by introducing
> multiple-argument functions into the proposed feature. That's going
> to add even more complexity, for instance there would need to be a way
> to specify which argument(s) the function was monotonic in. The C
> versus not-C locale aspect also shows that for textual arguments,
> it might matter which locale you're talking about.
>
> In short, this is looking awfully complicated, and I gauge the probable
> level of interest by the fact that you're the first person to ask for it
> in more than a dozen years of Postgres development.
>
> regards, tom lane
>
--
------------
pasman
From | Date | Subject | |
---|---|---|---|
Next Message | Pavel Stehule | 2011-09-25 20:44:17 | Re: New feature: accumulative functions. |
Previous Message | pasman pasmański | 2011-09-25 20:33:02 | Re: New feature: accumulative functions. |