Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1ZbYyF-0001NG-W2 for pgsql-hackers@arkaria.postgresql.org; Mon, 14 Sep 2015 18:59:20 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1ZbYyF-0005PN-0t for pgsql-hackers@arkaria.postgresql.org; Mon, 14 Sep 2015 18:59:19 +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) (envelope-from ) id 1ZbYwx-0003wj-3M for pgsql-hackers@postgresql.org; Mon, 14 Sep 2015 18:57:59 +0000 Received: from hook.sigaev.ru ([93.180.27.50]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84) (envelope-from ) id 1ZbYwt-0005yi-Ll for pgsql-hackers@postgresql.org; Mon, 14 Sep 2015 18:57:58 +0000 Received: from zorg.sigaev.ru (89-178-7-103.broadband.corbina.ru [89.178.7.103]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: teodor) by hook.sigaev.ru (Postfix) with ESMTPSA id 363A0B1918A; Mon, 14 Sep 2015 21:57:54 +0300 (MSK) Message-ID: <55F718B1.8030306@sigaev.ru> Date: Mon, 14 Sep 2015 21:57:53 +0300 From: Teodor Sigaev User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:36.0) Gecko/20100101 Firefox/36.0 SeaMonkey/2.33.1 MIME-Version: 1.0 To: Thomas Munro CC: Jim Nasby , Anastasia Lubennikova , pgsql-hackers Subject: Re: [PROPOSAL] Covering + unique indexes. References: <55F2C1BC.3010109@postgrespro.ru> <55F2CCD0.7040608@postgrespro.ru> <55F6F7AD.4080307@BlueTreble.com> <55F70D0A.2030503@sigaev.ru> In-Reply-To: Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org > It surprised me that you can INCLUDE extra columns on non-UNIQUE > indexes, since you could just add them as regular indexed columns for > the same effect. It looks like when you do that in SQL Server, the > extra columns are only stored on btree leaf pages and so can't be used > for searching or ordering. I don't know how useful that is or if we > would ever want it... but I just wanted to note that difference, and Agree > that the proposed UNIQUE ON FIRST n COLUMNS syntax and catalog change > can't express that. Proposal suggests to work only with unique index by exactly your reasons above. -- Teodor Sigaev E-mail: teodor@sigaev.ru WWW: http://www.sigaev.ru/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers