Received: from localhost (maia-3.hub.org [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id B916C9FBDC6 for ; Thu, 26 Jul 2007 04:33:15 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 36729-04 for ; Thu, 26 Jul 2007 04:33:08 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from outR.internet-mail-service.net (outR.internet-mail-service.net [216.240.47.241]) by postgresql.org (Postfix) with ESMTP id 445C89FBD72 for ; Thu, 26 Jul 2007 04:33:12 -0300 (ADT) Received: from mx0.idiom.com (HELO idiom.com) (216.240.32.160) by out.internet-mail-service.net (qpsmtpd/0.32) with ESMTP; Thu, 26 Jul 2007 00:33:10 -0700 Received: from [192.168.1.109] (adsl-71-135-174-255.dsl.pltn13.pacbell.net [71.135.174.255]) by idiom.com (Postfix) with ESMTP id 323E2125A2A for ; Thu, 26 Jul 2007 00:33:10 -0700 (PDT) Message-ID: <46A84E35.7000609@obviously.com> Date: Thu, 26 Jul 2007 00:33:09 -0700 From: Bryce Nesbitt User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.4) Gecko/20061107 SUSE/1.1.2-1.1 SeaMonkey/1.1.2 MIME-Version: 1.0 To: pgsql-sql@postgresql.org Subject: How to cast, if type has spaces in the name Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200707/152 X-Sequence-Number: 28887 How do I specify a cast, if the type name has spaces? foo::integer is easy, but foo::'timestamp without time zone' is more murky. In my case I have a table, and a view. For no apparent reason the table has timestamp without time zone, but I need timestamp with time zone. I'm using "select column at time zone 'PST8PDT'" to solve this problem. But wonder about the general case of typecasting when the type name is not a single symbol.