How to cast, if type has spaces in the name

From: Bryce Nesbitt <bryce1(at)obviously(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: How to cast, if type has spaces in the name
Date: 2007-07-26 07:33:09
Message-ID: 46A84E35.7000609@obviously.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

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.

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message A. Kretschmer 2007-07-26 07:39:18 Re: How to cast, if type has spaces in the name
Previous Message Bryce Nesbitt 2007-07-26 07:30:00 Re: The nested view from hell - Restricting a subquerry