Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1c4rcK-0004wA-1O for pgsql-bugs@arkaria.postgresql.org; Thu, 10 Nov 2016 15:50:20 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1c4rcJ-0005XC-GD for pgsql-bugs@arkaria.postgresql.org; Thu, 10 Nov 2016 15:50:19 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1c4rbf-0004kk-4T for pgsql-bugs@postgresql.org; Thu, 10 Nov 2016 15:49:39 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1c4rbc-000085-Lm for pgsql-bugs@postgresql.org; Thu, 10 Nov 2016 15:49:38 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id uAAFnZpW016044; Thu, 10 Nov 2016 10:49:35 -0500 From: Tom Lane To: Steve Randall cc: pgsql-bugs@postgresql.org Subject: Re: Parallel Scan Bug: invalid attnum: 0 In-reply-to: References: <23469.1478717448@sss.pgh.pa.us> Comments: In-reply-to Steve Randall message dated "Thu, 10 Nov 2016 07:56:41 -0600" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <16042.1478792975.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Thu, 10 Nov 2016 10:49:35 -0500 Message-ID: <16043.1478792975@sss.pgh.pa.us> X-Pg-Spam-Score: -4.8 (----) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org Steve Randall writes: > I have been able to reproduce the error in my development environment. > EXPLAIN output is attached. EXPLAIN ANALYZE fails with the error > mentioned. Ah, I've duplicated it. My previous attempt to reverse-engineer your test case was not selecting a partial-aggregation plan. Immediate impression is that the logic for planning partial grouped aggregation did not get the zero-sort-keys case right. In my hands it produces TRAP: BadArgument("!(nkeys > 0)", File: "tuplesort.c", Line: 763) 2016-11-10 10:44:26.955 EST [14415] LOG: server process (PID 15726) was te= rminated by signal 6: Aborted but in a non-assert build of course you'd get some other misbehavior. regards, tom lane --=20 Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs