Question.. is there a way that I can get Postgres to return the tz as
supplied on the insert statement

insert into TTSTZ(RNUM, CTSTZ) values ( 0, null);
insert into TTSTZ(RNUM, CTSTZ) values ( 1, timestamp with time zone
'2000-12-31 12:00:00.0-05:00');
insert into TTSTZ(RNUM, CTSTZ) values ( 2, timestamp with time zone
'2000-12-31 12:00:00+00:00');
insert into TTSTZ(RNUM, CTSTZ) values ( 3, timestamp with time zone
'2000-12-31 12:00:00.0+05:00');

select rnum, CTSTZ

0;""
1;"2000-12-31 12:00:00-05"
2;"2000-12-31 07:00:00-05"
3;"2000-12-31 02:00:00-05"

select rnum, extract (hour from ctstz), extract (timezone_hour from ctstz)
from ttstz

0;;
1;12;-5
2;7;-5
3;2;-5

Reply via email to