Re: Fabian Pascal and RDBMS deficiencies in fully implementing

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Christopher Browne <cbbrowne(at)acm(dot)org>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Fabian Pascal and RDBMS deficiencies in fully implementing
Date: 2006-06-14 08:23:45
Message-ID: 20060614082345.GA4748@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

On Tue, Jun 13, 2006 at 05:23:56PM -0400, Christopher Browne wrote:
> > [3] http://www.intelligententerprise.com/010327/celko_online.jhtml;jsessionid=NDIHEWXGL4TNKQSNDBNSKHSCJUMEKJVN
>
> The sample problem in [3] is one that shows pretty nicely a
> significant SQL weakness; it's very painful to build SQL to do complex
> things surrounding cumulative statistics.

I havn't managed to wrap my brain around them yet, but this seems like
something that SQL WINDOW functions would be able to do. For each row
define the window frame to be all the preceding rows, do a SUM() and
divide that over the total. Or perhaps the PERCENT_RANK() function does
this already, not sure.

Mind you, postgres doesn't support them yet, but it's interesting that
it may be possible at all...

Have a nice day,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Daniel McBrearty 2006-06-14 08:53:36 table has many to many relationship with itself - how to implement?
Previous Message louis gonzales 2006-06-14 06:41:40 Re: Problem Connecting to 5432

Browse pgsql-hackers by date

  From Date Subject
Next Message Martijn van Oosterhout 2006-06-14 08:34:19 Re: postgresql and process titles
Previous Message Michael Glaesemann 2006-06-14 06:47:16 Re: Ranges for well-ordered types