On Thu, 1 Jul 2004, John Pagakis wrote:
> Odd though. There seems to be a bug in the cygwin implementation of
> postgres. Tim McAuley ran into the same problem I did and posted here:
>
> http://groups.google.com/groups?q=cast+timeofday+timestamp&hl=en&lr=&ie=UTF-
> 8&selm=bgdif2%2414kk%241%40FreeBSD.csie.NCTU.edu.tw&rnum=5
>
> To save you from having to follow the link - an attempt to cast TIMEOFDAY()
> to TIMESTAMP in cygwin's implementation results in:
>
> ERROR: Bad timestamp external representation 'Thu Jul 01 22:29:25.402375
> 2004 USMST'
>
Well the JDBC list isn't the best place to get help on this, but I don't
see a problem here, so I imagine it is dependent on your timezone. (I'm
PDT). Postgresql has some confusion on timezone names because it has an
internal list of timezones, but also uses the system libraries to
manipulate them as well. This will be rectified in 7.5 when all timezone
handling is moved under the control of postgresql libraries, but for now I
will note that USMST does not appear in src/backend/utils/adt/datetime.c.
Also notice that the original bug report you cite shows different timezone
results for timeofday. cygwin shows GMTDT while linux shows IST.
Checking datetime.c again IST is included, but GMTDT is not.
Kris Jurka