From: Tom Lane <tgl@sss.pgh.pa.us>
To: sean.johnston@edgeintelligence.com
Cc: pgsql-bugs@postgresql.org, Robert Haas <robertmhaas@gmail.com>
Cc: Jeevan Chalke <jeevan.chalke@enterprisedb.com>
Cc: Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>
Subject: Re: BUG #14890: Error grouping by same column twice using FDW
Date: Tue, 07 Nov 2017 17:29:41 -0500
Message-ID: <10660.1510093781@sss.pgh.pa.us> (raw)
In-Reply-To: <20171107134948.1508.94783@wrigleys.postgresql.org>
References: <20171107134948.1508.94783@wrigleys.postgresql.org>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
sean.johnston@edgeintelligence.com writes:
> select col1, col1 from loop_tbl group by 1, 2;
> psql:t.sql:7: ERROR: targetlist item has multiple sortgroupref labels
This is the fault of commit 7012b132d ("Push down aggregates to remote
servers"), which imagined that postgres_fdw can use
apply_pathtarget_labeling_to_tlist() for situations well beyond that
function's limited abilities. I kinda suspect that foreign_grouping_ok()
has got more bugs than this with complicated sortgroupref situations, too;
its willingness to scribble on the sortgrouprefs doesn't look like a great
idea to me.
regards, tom lane
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
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, sean.johnston@edgeintelligence.com, robertmhaas@gmail.com, jeevan.chalke@enterprisedb.com, ashutosh.bapat@enterprisedb.com
Subject: Re: BUG #14890: Error grouping by same column twice using FDW
In-Reply-To: <10660.1510093781@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