pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: lukas.eder@gmail.com
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #15262: "unexpected end of tuplestore" error when using new GROUPS window function clause
Date: Mon, 09 Jul 2018 18:29:34 -0400
Message-ID: <13420.1531175374@sss.pgh.pa.us> (raw)
In-Reply-To: <153086788677.17476.8002640580496698831@wrigleys.postgresql.org>
References: <153086788677.17476.8002640580496698831@wrigleys.postgresql.org>

=?utf-8?q?PG_Bug_reporting_form?= <noreply@postgresql.org> writes:
> This error can be reproduced easily as follows

>   postgres=# SELECT count(*) OVER (GROUPS 1 PRECEDING) FROM (VALUES (1),
> (2), (2)) t(v);
>   ERROR:  unexpected end of tuplestore

In an assert-enabled build I get an assert failure from this.  I think
this is the same problem Masahiko Sawada noted in

https://www.postgresql.org/message-id/CAD21AoDrWqycq-w_+Bx1cjc+YUhZ11XTj9rfxNiNDojjBx8Fjw@mail.gmail...

and as in that thread, I think what we really should be doing here is
giving a parse error.  What would you expect GROUPS mode to do without
an ORDER BY to define the grouping?

			regards, tom lane




view thread (3+ messages)  latest in thread

Message-ID: <13420.1531175374@sss.pgh.pa.us>
Permalink:  ../13420.1531175374@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/13420.1531175374@sss.pgh.pa.us

 · 

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-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, lukas.eder@gmail.com, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #15262: "unexpected end of tuplestore" error when using new GROUPS window function clause
  In-Reply-To: <13420.1531175374@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