[postgis-devel] Overloaded operator?

Martin Davis mtnclimb at gmail.com
Tue Oct 19 17:12:10 PDT 2021


Don't think there is a -> operator in PostGIS?

The Timescale function pipelines are a clever trick, but seems a bit ugly
to me under the covers.  The -> is apparently building building and then
evaluating its own expression tree, which seems like a huge duplication of
effort.

It also seems questionable to use this as instead of a pure SQL approach,
since that removes any chance of using the SQL engine to optimize the
query.  Granted the SQL syntax is not as readable as it could be.

For sure deeply nested function call chains are hard to read and modify.
And we see this in PostGIS a lot.  It would be very nice if Postgres had a
function pipeline operator built in, like Elixir's:
https://elixirschool.com/en/lessons/basics/pipe_operator

On Tue, Oct 19, 2021 at 3:51 PM Bruce Rindahl <bruce.rindahl at gmail.com>
wrote:

> This looks interesting to me:
>
> https://blog.timescale.com/blog/function-pipelines-building-functional-programming-into-postgresql-using-custom-operators/amp/
> But will their definition of an -> operator conflict with similar postgis
> operators?
> Just curious
> _______________________________________________
> postgis-devel mailing list
> postgis-devel at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/postgis-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-devel/attachments/20211019/1ad4aaab/attachment.html>


More information about the postgis-devel mailing list