Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1egEQl-0006zV-Kd for pgsql-bugs@arkaria.postgresql.org; Mon, 29 Jan 2018 18:45:23 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1egEQj-0005oU-M2 for pgsql-bugs@arkaria.postgresql.org; Mon, 29 Jan 2018 18:45:21 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1egEQj-0005oK-GK for pgsql-bugs@lists.postgresql.org; Mon, 29 Jan 2018 18:45:21 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1egEQg-0001bi-9D for pgsql-bugs@postgresql.org; Mon, 29 Jan 2018 18:45:21 +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 w0TIjAnq006341; Mon, 29 Jan 2018 13:45:10 -0500 From: Tom Lane To: Andres Freund cc: Tomas Vondra , "Todd A. Cook" , Thomas Munro , PostgreSQL Bugs Subject: Re: BUG #14932: SELECT DISTINCT val FROM table gets stuck in an infinite loop In-reply-to: <20180129183049.xqoejgs52x37xnyr@alap3.anarazel.de> References: <219b37b2-d740-d04a-203a-49ae422028f7@blackducksoftware.com> <1773c302-2fb1-749f-8ccc-62b23617c5ac@blackducksoftware.com> <25629.1512580464@sss.pgh.pa.us> <20171206171923.dg7phzfh7nb4lou3@alap3.anarazel.de> <7de4b2d6-b119-7d15-04d8-4c0fcb29cbc3@2ndquadrant.com> <20180126234537.dyu6jwnqz7snpq7n@alap3.anarazel.de> <14184.1517010515@sss.pgh.pa.us> <20180129010213.rt3nu73ilff756f6@alap3.anarazel.de> <5429.1517250335@sss.pgh.pa.us> <20180129183049.xqoejgs52x37xnyr@alap3.anarazel.de> Comments: In-reply-to Andres Freund message dated "Mon, 29 Jan 2018 10:30:49 -0800" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <6339.1517251510.1@sss.pgh.pa.us> Date: Mon, 29 Jan 2018 13:45:10 -0500 Message-ID: <6340.1517251510@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Andres Freund writes: > On 2018-01-29 13:25:35 -0500, Tom Lane wrote: >> I disagree: people should reasonably expect the same query and same >> data and same plan to give consistent results. When we stuck in the >> "synchronous seqscans" feature, which broke that property, we were very >> quickly forced by user complaints to provide a way to shut it off. >> I'm also concerned that we'd have to lobotomize a bunch of regression >> test cases to ensure stable results there. > I don't think the cases really compare. For one there's no "natural > order" like insertion order for seqscans (in simplistic cases). For > another hashaggs/joins/whatnot are *already* architecture dependent, so > there's ORDER BYs for pretty much everything already - I needed to add a > single ORDER BY to make things stable over ~50 regression runs. As developers who see test results from a variety of architectures, we're aware that hash ops don't give stable results across machines. Most end users aren't going to know or care about that: they're running on one architecture and up to now they've gotten stable results from hash ops. I think we *will* get pushback if we change that. Also, the fact that you needed one more ORDER BY in testing on a single machine is already proof of my worry about the regression tests, and it'll only get worse when testing across a variety of machines. regards, tom lane