pg.ddx.io pgsql-hackers@postgresql.org mailing list archive
help / color / mirror / Atom feed From: Tom Lane <tgl@sss.pgh.pa.us>
To: Oliver Ford <ojford@gmail.com>
Cc: David G. Johnston <david.g.johnston@gmail.com>
Cc: Erik Rijkers <er@xs4all.nl>
Cc: Pg Hackers <pgsql-hackers@postgresql.org>
Subject: Re: Add RANGE with values and exclusions clauses to the Window Functions
Date: Wed, 07 Feb 2018 00:28:04 -0500
Message-ID: <26389.1517981284@sss.pgh.pa.us> (raw )
In-Reply-To: <17947.1517767809@sss.pgh.pa.us >
References: <CAGMVOdu9sivPAxbNN0X+q19Sfv9edEPv=HibOJhB14TJv_RCQg@mail.gmail.com >
<b2374b9461c349b17b50c77f3a70e1a1@xs4all.nl >
<CAGMVOdsopg5ZAuJh9+ceq-s0pU2qqZsZn-jbL4A1c=h1iWaZVA@mail.gmail.com >
<CAGMVOdvrZCwJg0BngM9GMO+LK=j20vhSfdk1gTTBNNH311Vgsw@mail.gmail.com >
<bc8a1d397fa81d6ae33c297d0224184b@xs4all.nl >
<2c084c1c2bf599ceb2afa87874de8bc1@xs4all.nl >
<CAGMVOdvETRCKpeT06Uoq5RsNUOdH7d1iYy7C1Pze=L5=gBzs-Q@mail.gmail.com >
<cdbe62a6eaddae00fa770c09ed346fc0@xs4all.nl >
<CAGMVOdttRSUU3=tjgdhr902HmUVL1GLQWG0ZTVXi7OY59Xo0Xw@mail.gmail.com >
<13279.1515535159@sss.pgh.pa.us >
<CAGMVOdtYSNJusckQ_9vBkMsZBQzan=Uw-Z-uYG2fD9rZ2TP7pA@mail.gmail.com >
<4139.1515567978@sss.pgh.pa.us >
<CAGMVOdvJMfOzm0v4psCoAaVGfCbdFwNKzaSEhfTj8rE9UCz-eQ@mail.gmail.com >
<c30e6457a6de09d26425af997f71996e@xs4all.nl >
<CAGMVOdtGe=30u6D2WqwvWchE+-yNb9jKnEeG8BHyw7jHiGPR7w@mail.gmail.com >
<27788.1517069693@sss.pgh.pa.us >
<CAGMVOduaHeA8q+kvCqX-UfuV_=jHvb-XK+1KJEiNy80Drk=y_A@mail.gmail.com >
<10568.1517261334@sss.pgh.pa.us >
<CAGMVOdtJZCXQRO1HQvGWTfzxrP0cTtxWXfXJ58EC2f2GgSQ+9w@mail.gmail.com >
<14068.1517266223@sss.pgh.pa.us >
<CAGMVOdtkUxmN8iLF5cQSF7+8kZA_fDYuBBcN0BvjDKbOjCvUdw@mail.gmail.com >
<18875.1517272139@sss.pgh.pa.us >
<CAGMVOdv0G=cSEFdbP6om7920cd7d_GOin8H+dRi6jMpC_9C_2g@mail.gmail.com >
<CAGMVOdtHgHbhKxZfduUbQNX8o5b0bTiCKV5A=PjTS7w6i8QFKw@mail.gmail.com >
<c970520d467f2d49ca45c20a3f0a8533@xs4all.nl >
<e0b02cb1e6412400c1def920f8f24d02@xs4all.nl >
<CAGMVOdv5D67XaOWAys_cr8cFiq4z5ywKnQo1rovFW0tbnVyYuA@mail.gmail.com >
<15869.1517443560@sss.pgh.pa.us >
<CAKFQuwZr9BiEr_kRmJwAE__k_O_fd5v0t0SDLykSJNB0ECe51w@mail.gmail.com >
<CAGMVOduju1k4kbmsjCbYHDv=ghTf3X05sGzMtDTPzsjXUmr05Q@mail.gmail.com >
<CAKFQuwbiM7TsopVvwQ59fgg31rFhNXxbgpSPRD72ASkehzCkcQ@mail.gmail.com >
<CAGMVOduKGh6dazo-iyfYDvVRm_rv9ZorPLyE40daDyGR-w6vvg@mail.gmail.com >
<17947.1517767809@sss.pgh.pa.us >
I wrote:
> [ 0001-window-frame-v14.patch ]
Pushed after further hacking on the documentation and test cases.
I went ahead with the "value" to "offset" terminology change, too.
You mentioned upthread that you were interested in adding more in_range
support functions. I think it'd be a great idea to get that done for v11,
because according to my reading of the SQL spec, it expects "RANGE offset
PRECEDING/FOLLOWING" to work for any numeric type. See SQL:2011 7.11
<window clause> syntax rule 11-a-iii:
iii) The declared type of [the sort column] shall be numeric,
datetime, or interval. The declared type of [the offset] shall be
numeric if the declared type of SK is numeric; otherwise, it shall
be an interval type that ...
So we need in_range functions for float4, float8, and numeric if we
really want to claim with a straight face that we cover all of SQL:2011
here. I think that ought to be a small enough addition to deal with in
the final v11 commitfest, if you have time to prepare a patch this
month.
regards, tom lane
view thread (45+ messages) latest in thread
Message-ID: <26389.1517981284@sss.pgh.pa.us>
Permalink: ../26389.1517981284@sss.pgh.pa.us/
Also on: postgresql.org/message-id/26389.1517981284@sss.pgh.pa.us
copy link · copy postgr.es
reply Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, ojford@gmail.com, david.g.johnston@gmail.com, er@xs4all.nl
Subject: Re: Add RANGE with values and exclusions clauses to the Window Functions
In-Reply-To: <26389.1517981284@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox