Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1xRYdy-000000014up-0djo for pgsql-bugs@arkaria.postgresql.org; Thu, 12 Nov 2026 17:31:26 +0000 Received: from localhost ([127.0.0.1]:47742 helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.98.2) (envelope-from ) id 1xRYds-0000000451k-2lqr for pgsql-bugs@arkaria.postgresql.org; Thu, 12 Nov 2026 17:31:20 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]:40618) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1xRYVG-00000003jbf-1a1z for pgsql-bugs@lists.postgresql.org; Thu, 12 Nov 2026 17:22:26 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1xRYVE-00000000i5U-0th5 for pgsql-bugs@lists.postgresql.org; Thu, 12 Nov 2026 17:22:26 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.18.1/8.18.1) with ESMTP id 6ACHMKl4044952; Thu, 12 Nov 2026 12:22:20 -0500 DKIM-Filter: OpenDKIM Filter v2.11.0 sss.pgh.pa.us 6ACHMKl4044952 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sss.pgh.pa.us; s=default; t=1794504140; bh=8m0yMPhhVaRzFNkRM31qorEgrW3PQGR0/Wc9i5t2mho=; h=From:To:cc:Subject:In-reply-to:References:Date:From; b=hYLnZiF5K7xu/zlTuo+CkLejHAjcx0fG5K37/yKDcckSQhxgcF+glbcjXbvqnEPi6 b//AofKmA1Pp8fTHUIvpXvA3Fy5EQzPj9pHuIGH8mHJGRz9cKHXja9V27jdnFchtEA Zy3MBm/5yux0cOLJhN9GSMEFvnGAK61Uz7dUpACk= From: Tom Lane To: Venu K cc: pgsql-bugs@lists.postgresql.org Subject: Re: BUG #19826: corr()/regr_r2() of constant input: NULL serially, 1 with partial aggregation In-reply-to: References: <19826-4b769cb5342fdfe7@postgresql.org> <1382078.1793675027@sss.pgh.pa.us> <3406913.1794428629@sss.pgh.pa.us> Comments: In-reply-to Venu K message dated "Thu, 12 Nov 2026 21:43:30 +0530" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <44950.1794504140.1@sss.pgh.pa.us> Date: Thu, 12 Nov 2026 12:22:20 -0500 Message-ID: <44951.1794504140@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Venu K writes: > On Thu, Nov 12, 2026 at 1:53 AM Tom Lane wrote: >> Yeah, it seems clear that that test case is just made-up data, > The first six entries aren't made up: they are the transition states > for the regr_test rows with x IN (10,20,30) and x IN (80,100), which > the queries just above print. Only the commonX/commonY entries (7,8 > and 7,9) don't fit those rows, which have distinct X and Y values. Ah. Now that I think about it, the bogus commonX/commonY entries are probably my fault: they came in with 649828769, and I was not aware that the other columns matched some real state, so I just made them test both the NaN and non-NaN code paths. > v4 attached: your v3 plus those test changes and a paragraph about > them in the commit message. make check passes on master (b0496e3) > with assertions enabled. v4 seems good, pushed. Thanks for the report and patch! regards, tom lane