Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1j3UeL-0005zL-Qj for pgsql-performance@arkaria.postgresql.org; Mon, 17 Feb 2020 00:52:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1j3UeJ-0008NG-7Z for pgsql-performance@arkaria.postgresql.org; Mon, 17 Feb 2020 00:52:35 +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_SHA1:256) (Exim 4.89) (envelope-from ) id 1j3UeI-0008N8-RP for pgsql-performance@lists.postgresql.org; Mon, 17 Feb 2020 00:52:34 +0000 Received: from mail-yb1-xb43.google.com ([2607:f8b0:4864:20::b43]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1j3UeF-0007C6-1z for pgsql-performance@lists.postgresql.org; Mon, 17 Feb 2020 00:52:34 +0000 Received: by mail-yb1-xb43.google.com with SMTP id u26so4345327ybd.3 for ; Sun, 16 Feb 2020 16:52:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=rHyRjb6vHQbjxjh7r52VXCzgfznJv4WUP1b5kbVZ0ag=; b=qH+hlaZ3gtER1cOhWj+P/5rURaMRiV+QVra0IPZQQuvf9KwMG42HNHJE+ylV909xXH j25/03pm0MEA7aNyTn7oOAP5TVZG2B1FaHpkgzVoX2RUoNPND/rzBr6r3gA0oM2dnEWD GLhERHrQECEd9QzQqWMscd9DhIK8r5Gcny8F8ltHhJOFA0H/DhRpqyRdJuIJTuOOYJiy MbPcpaukZbDZwQXByLGNMmgkZOXvZEPjH/y4F/T4KSULObFfmo2KQxENk3L5spk3+egP ppGeiNAlQA9lPDbVZKPruf8tRFpZZeV1CPFBXbwIlFuvTrFUJEoZ/WnEackDbo6vfQVa V97w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=rHyRjb6vHQbjxjh7r52VXCzgfznJv4WUP1b5kbVZ0ag=; b=pTpGkPVdacbYDIyCDaQGd4BaJNvqXgED5jGN2AP/cMabS3VA0w7kk/hUwFY2OSaRDT VBgLkA1hyY3tlpoHhudmrloqoHcOd7LRe/MGH68F6ockGP+C/tlVLC78I+eCWR5H2q04 O7WrFyLZjYiWK9r/TwMkjV9aoy5rSeKw8HBRHysG/szs0rKu7K/ftvZSqKPpwVlbUAbz J+M1Wmsjqpiqo/6r5tBkdjpBhW0rnl+jtao4LQ/SuYPwAHoZIbdSYbTl8MYxJA+7u+pe gC1ujrnobqf2ySCiT/f0+MWHeob0C44FAlt103QbkClpLdylfm/itbf4WnujwfRqfAB6 N1iQ== X-Gm-Message-State: APjAAAUUNrGDsc0o/y+wv57dGPNv9A2B62D9ryzgRoPFnzO+GKYDnDB0 Gg5gdwENIBevn5dZiuJNK8XAxw== X-Google-Smtp-Source: APXvYqz9uMQeWIV9xIdRvw3t1YgJ/s7sS8IsxPpj7GJctxlyaxVF7vhN4ubKM4I/ChqeGEaoyVZN+g== X-Received: by 2002:a25:5603:: with SMTP id k3mr9324275ybb.515.1581900749131; Sun, 16 Feb 2020 16:52:29 -0800 (PST) Received: from pryzbyj (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id o69sm5895113ywd.38.2020.02.16.16.52.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 16 Feb 2020 16:52:28 -0800 (PST) Received: by pryzbyj (Postfix, from userid 1000) id 0DE3E800897; Sun, 16 Feb 2020 18:52:26 -0600 (CST) Date: Sun, 16 Feb 2020 18:52:26 -0600 From: Justin Pryzby To: Mike Sofen Cc: Tom Lane , Laurenz Albe , MingJu Wu , pgsql-performance@lists.postgresql.org Subject: Re: Partial index creation always scans the entire table Message-ID: <20200217005226.GK31889@telsasoft.com> References: <43b329d274c3535c75d2fbd6912b5ae8e3e51582.camel@cybertec.at> <19549.1581867005@sss.pgh.pa.us> <05fc01d5e52b$3c3d1c50$b4b754f0$@runbox.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <05fc01d5e52b$3c3d1c50$b4b754f0$@runbox.com> User-Agent: Mutt/1.5.24 (2015-08-30) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Sun, Feb 16, 2020 at 04:43:10PM -0800, Mike Sofen wrote: > >From: Tom Lane Sent: Sunday, February 16, 2020 7:30 > AM > >I've seen people try to do this before. I wonder if the manual page about > partial indexes should explicitly say "don't do that". > > regards, tom lane > > Yes please (seriously). The utter beauty of Postgres is the flexibility and > power that its evolutionary path has allowed/created. The tragic danger is > that the beauty is fairly easy to misapply/misuse. Quote. Enough rope to shoot yourself in the foot. Would you care to suggest text to be included here ? https://www.postgresql.org/docs/devel/indexes-partial.html -- Justin