X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 0891952896 for ; Wed, 1 Jun 2005 10:40:06 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 83727-07 for ; Wed, 1 Jun 2005 13:40:03 +0000 (GMT) Received: from mr1.surnet.cl (smtp1.surnet.cl [216.155.73.162]) by svr1.postgresql.org (Postfix) with ESMTP id E054652887 for ; Wed, 1 Jun 2005 10:39:59 -0300 (ADT) Received: from smtp1.surnet.cl (216.155.73.168) by mr1.surnet.cl (7.0.031.3) id 42587EDE00B17C0F; Wed, 1 Jun 2005 09:39:30 -0400 Received: from smtp1.surnet.cl (mr1.surnet.cl []) by mr1.surnet.cl ([216.155.73.168]); Wed, 01 Jun 2005 13:39:30 +0000 Received: from cluster.surnet.cl (216.155.73.164) by smtp1.surnet.cl (7.0.031.3) id 42587C6E0091A528; Wed, 1 Jun 2005 09:39:29 -0400 Received: from localhost (200.85.219.91) by cluster.surnet.cl (7.0.024) id 4276578F0041C51A; Wed, 1 Jun 2005 09:40:00 -0400 Received: by localhost (Postfix, from userid 1000) id 7D35DC00205; Wed, 1 Jun 2005 09:40:09 -0400 (CLT) Date: Wed, 1 Jun 2005 09:40:09 -0400 From: Alvaro Herrera To: Marc Mamin Cc: pgsql-performance@postgresql.org Subject: Re: TIP 9: the planner will ignore... & datatypes Message-ID: <20050601134009.GA23141@surnet.cl> References: <1117616779.3844.903.camel@localhost.localdomain> <29804.1117619106@www18.gmx.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <29804.1117619106@www18.gmx.net> User-Agent: Mutt/1.5.9i X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=1.668 tagged_above=0 required=5 tests=AWL, DNS_FROM_RFC_ABUSE, DNS_FROM_RFC_POST, FORGED_RCVD_HELO X-Spam-Level: * X-Archive-Number: 200506/14 X-Sequence-Number: 12652 On Wed, Jun 01, 2005 at 11:45:06AM +0200, Marc Mamin wrote: > TIP 9: the planner will ignore your desire to choose an index scan if your > joining column's datatypes do not match > > > But INT2, INT4, INT8 and "SERIAL" are considered to be a unique datatype. > Am I Right? No, they weren't when this tip was written. As of 8.0 however this tip is no longer the complete truth; we do allow cross-type index scans. -- Alvaro Herrera () "I suspect most samba developers are already technically insane... Of course, since many of them are Australians, you can't tell." (L. Torvalds)