Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lpyHJ-0004ZC-C8 for pgsql-hackers@arkaria.postgresql.org; Sun, 06 Jun 2021 19:17:45 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lpyHI-0005N0-AU for pgsql-hackers@arkaria.postgresql.org; Sun, 06 Jun 2021 19:17:44 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lpyHI-0005Mr-2t for pgsql-hackers@lists.postgresql.org; Sun, 06 Jun 2021 19:17:44 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lpyHC-0006Bc-3d for pgsql-hackers@postgresql.org; Sun, 06 Jun 2021 19:17:43 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 156JHa13660937; Sun, 6 Jun 2021 15:17:36 -0400 From: Tom Lane To: Tomas Vondra cc: Noah Misch , Dean Rasheed , Justin Pryzby , PostgreSQL Hackers Subject: Re: PoC/WIP: Extended statistics on expressions In-reply-to: <4c98203c-8364-bb76-b502-d7b323ba55ba@enterprisedb.com> References: <1ed534fb-b42b-f008-35ee-4eb930b0088f@enterprisedb.com> <2cb8a7cd-664f-8681-6ce9-790a50e3c78f@enterprisedb.com> <096d26e1-f053-a039-047d-a050dbb80ac6@enterprisedb.com> <078de413-8e4e-343e-fac1-eb61fd389925@enterprisedb.com> <20210606053740.GB297923@rfd.leadboat.com> <4c98203c-8364-bb76-b502-d7b323ba55ba@enterprisedb.com> Comments: In-reply-to Tomas Vondra message dated "Sun, 06 Jun 2021 21:13:17 +0200" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <660935.1623007056.1@sss.pgh.pa.us> Date: Sun, 06 Jun 2021 15:17:36 -0400 Message-ID: <660936.1623007056@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Tomas Vondra writes: > On 6/6/21 7:37 AM, Noah Misch wrote: >> This added a "transformed" field to CreateStatsStmt, but it didn't mention >> that field in src/backend/nodes. Should those functions handle the field? > Yup, that's a mistake - it should do whatever CREATE INDEX is doing. Not > sure if it can result in error/failure or just inefficiency (due to > transforming the expressions repeatedly), but it should do whatever > CREATE INDEX is doing. I'm curious about how come the buildfarm didn't notice this. The animals using COPY_PARSE_PLAN_TREES should have failed. The fact that they didn't implies that there's no test case that makes use of a nonzero value for this field, which seems like a testing gap. regards, tom lane