Re: Postgres and timezones

From: Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>
To: "'Steve Rogerson *EXTERN*'" <steve(dot)pg(at)yewtc(dot)demon(dot)co(dot)uk>, "pgsql-general(at)postgresql(dot)org >> PG-General Mailing List" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Postgres and timezones
Date: 2016-01-20 12:53:39
Message-ID: A737B7A37273E048B164557ADEF4A58B537D44E3@ntex2010i.host.magwien.gv.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Steve Rogerson wrote:
> Hi, this is wrong:
>
> # select to_char('2016-01-20 00:00'::timestamp at time zone 'Europe/Lisbon',
> 'TZ');
> to_char
> ---------
> GMT
> (1 row)
>
>
> It should be WET, "Western European Time". Is there something I'm doing wrong?

That query will always give you your local timezone.

Here in Austria I get:

test=> select to_char('2016-01-20 00:00'::timestamp at time zone 'Asia/Yerevan', 'TZ');
┌─────────┐
│ to_char │
├─────────┤
│ CET │
└─────────┘
(1 row)

Yours,
Laurenz Albe

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Steve Rogerson 2016-01-20 13:24:24 Re: Postgres and timezones
Previous Message Thom Brown 2016-01-20 12:35:48 Re: Syntax error for Function