How to get correct local time

Поиск
Список
Период
Сортировка
От Andrus
Тема How to get correct local time
Дата
Msg-id 49EECE30EBB14603AA9799B439528F7E@dell2
обсуждение исходный текст
Ответ на Re: How to drop user if objects depend on it  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
    select current_time at time zone 'GMT-2'

returns

"11:54:40.22045+02"

but correct local time in Windows is one hour different:

12:54

How to get correct local time ?


Using

"PostgreSQL 9.6.0, compiled by Visual C++ build 1800, 32-bit"

with  standard postgresql.conf file in Windows 10
Same issue occurs also in ealier Postgres and in earlier windows.

Server time in Windows is correct.

Daylight saving time was changed by one hour a week ago.
Maybe postgres didnt recognized it.

Posted also in

http://stackoverflow.com/questions/43090328/how-to-return-correct-local-time-in-postgres

Andrus.



В списке pgsql-general по дате отправления:

Предыдущее
От: Karsten Hilbert
Дата:
Сообщение: Re: Postgres Permissions Article
Следующее
От: Vitaly Burovoy
Дата:
Сообщение: Re: How to get correct local time