X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id E6BE632A90B for ; Mon, 11 Oct 2004 23:32:11 +0100 (BST) 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 91020-07 for ; Mon, 11 Oct 2004 22:32:07 +0000 (GMT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id 798B032A2F0 for ; Mon, 11 Oct 2004 23:32:08 +0100 (BST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id i9BMW4A2024904; Mon, 11 Oct 2004 18:32:04 -0400 (EDT) To: Rosser Schwarz Cc: pgsql-admin@postgresql.org Subject: Re: indices and casts In-reply-to: <37d451f704101115152fa2acc8@mail.gmail.com> References: <37d451f704101115152fa2acc8@mail.gmail.com> Comments: In-reply-to Rosser Schwarz message dated "Mon, 11 Oct 2004 17:15:41 -0500" Date: Mon, 11 Oct 2004 18:32:04 -0400 Message-ID: <24903.1097533924@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200410/161 X-Sequence-Number: 15154 Rosser Schwarz writes: > Is it possible to do something functionally equivalent to "CREATE > INDEX name ON table USING btree(column::date)"? That statement yields > a syntax error on the "::". CREATE INDEX name ON table USING btree((column::date)) See the docs concerning indexes on expressions (formerly called functional indexes). The parens are needed to avoid syntactic ambiguity associated with the optional opclass name ... regards, tom lane