Hello,
I want write a function that converts a timestamp with time zone to the UTC
zone. But it should all be stored in the winter time.
For example, it must now, in the summer, the German time back by 2 hours and
in the winter time only 1 hour. But it expects only back one hour.
Is there a func
I find it difficult to understand you.
But the input I can not change:
>SELECT
>to_char(CONVERT_TO_UTC( '2011-03-22 14:17:00+01'::timestamptz
,'CET'),'-mm-dd hh12:MI:SS') AS winter,
>to_char(CONVERT_TO_UTC( '2011-04-22 14:17:00+02'::timestamptz
,'CET'),'-mm-dd hh24:MI:SS') AS summer;
T
Very good!
Another question:
I want to convert the string to the type TIMESTAMP WITH TIME ZONE. What do I
have to format? 'TZ' does not.
select to_timestamp('2011-03-22 14:17:00 Europe/Berlin', '-MM-DD
HH:MI:SS TZ')
---
FEHLER: Formatmuster »TZ«/»tz« werden in to_date nicht unterstützt
-