> $ uname -a > FreeBSD ninja1.internal 4.5-STABLE FreeBSD 4.5-STABLE #0: Fri Apr 5 18:08:12 PST >2002 [EMAIL PROTECTED]:/opt/obj/opt/src/sys/NINJA i386 > $ psql > # SELECT timestamp '2002-4-7 2:0:0.0'; > timestamptz > ------------------------ > 2036-06-02 22:57:08-07 > # SELECT version(); > version > ------------------------------------------------------------ > PostgreSQL 7.2 on i386--freebsd4.5, compiled by GCC 2.95.3 > This isn't happy making. What OS are you running? Seems like a lower > level problem. Do you know if it's a system call making the > formatting call?
PostgreSQL uses system calls to get the current time zone if it is not specified in the input string. I'm running a fairly new Linux (Mandrake distro), which has the zinc package as part of glibc-2.2.4 Do you have another way to verify your time zone setup? Do you have the "zdump" command to look at your time zone info? If you want to step through your PostgreSQL code, I could give you some suggestions on what to look for: 1) run the backend using "gdb postgres" 2) before telling gdb to "run", set a breakpoint on DecodeDateTime and DetermineLocalTimeZone. Use "b DecodeDateTime". 3) run the program. Use "run <dbname>" where <dbname> might be your user name. 4) at the prompt, type in the above query. 5) at first breakpoint, continue by typing "c". 6) at the DetermineLocalTimeZone breakpoint, start stepping through code with "s". Check values as you go along. hth - Thomas ---------------------------(end of broadcast)--------------------------- TIP 5: Have you checked our extensive FAQ? http://www.postgresql.org/users-lounge/docs/faq.html