Re: plpgsql arrays

From: Matthew Wakeling <matthew(at)flymine(dot)org>
To: pgsql-performance(at)postgresql(dot)org
Subject: Re: plpgsql arrays
Date: 2009-04-06 11:47:40
Message-ID: alpine.DEB.2.00.0904061222590.791@aragorn.flymine.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Fri, 3 Apr 2009, Tom Lane wrote:
> Simon Riggs <simon(at)2ndQuadrant(dot)com> writes:
>> On Fri, 2009-04-03 at 10:04 -0400, Tom Lane wrote:
>>> I don't actually believe that a standard merge join algorithm will work
>>> with an intransitive join condition ...
>
>> I think it's a common enough problem that having a non-standard join
>> algorithm written for that case would be interesting indeed.
>
> Sounds like a great PhD thesis topic.

I agree it'd be very cool to have a non-standard join algorithm for this
built into Postgres. However it is nowhere near complicated enough for a
PhD thesis topic.

I'm just putting the finishing touches on a plpgsql implementation - in
order to perform the join on a asymmetric set of ranges, you just need to
keep two separate history lists as you sweep through the two incoming
streams. This would be sufficient for range constraints.

Matthew

--
Surely the value of C++ is zero, but C's value is now 1?
-- map36, commenting on the "No, C++ isn't equal to D. 'C' is undeclared
[...] C++ should really be called 1" response to "C++ -- shouldn't it
be called D?"

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Mario Splivalo 2009-04-06 12:20:47 Re: Forcing seq_scan off for large table joined with tiny table yeilds improved performance
Previous Message Albe Laurenz 2009-04-06 10:47:11 Re: probelm with alter table add constraint......