X-Original-To: pgsql-performance-postgresql.org@postgresql.org Received: from localhost (wm.hub.org [200.46.204.128]) by postgresql.org (Postfix) with ESMTP id BF98C9FB255 for ; Tue, 22 Aug 2006 18:12:48 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.128]) (amavisd-new, port 10024) with ESMTP id 62877-07 for ; Tue, 22 Aug 2006 21:12:36 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey- Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by postgresql.org (Postfix) with ESMTP id 21A929FA4D9 for ; Tue, 22 Aug 2006 18:12:36 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.6/8.13.6) with ESMTP id k7MLCXX5011770; Tue, 22 Aug 2006 17:12:33 -0400 (EDT) To: espero7757@gmx.net cc: pgsql-performance@postgresql.org Subject: Re: query planner: automatic rescribe of LIKE to BETWEEN ? In-reply-to: <200608221922.59734.espero7757@gmx.net> References: <200608221922.59734.espero7757@gmx.net> Comments: In-reply-to Ulrich Habel message dated "Tue, 22 Aug 2006 19:22:59 +0200" Date: Tue, 22 Aug 2006 17:12:33 -0400 Message-ID: <11769.1156281153@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=3.816 tagged_above=0 required=5 tests=SPF_HELO_SOFTFAIL, SPF_SOFTFAIL X-Spam-Level: *** X-Archive-Number: 200608/361 X-Sequence-Number: 20546 Ulrich Habel writes: > Anythings speeks against this hack? Only that it was done years ago. As Alvaro mentions, if you are using a non-C locale then you need non-default index opclasses to get it to work. Non-C locales usually have index sort orders that don't play nice with this conversion. regards, tom lane