Forum OpenACS Q&A: Response to to_char(now(), 'YYYY') and time zones

Collapse
Posted by Don Baccus on
PG 7.1 now supports subselects in from clauses, so

select to_char(utc, 'YYYYY') from (select now() as utc at time zone 'utc')

Should work, maybe?  You might need to give a name to the subselect and fully qualify the argument to to_char, I didn't try it...