Re: [GENERAL] binary timestamp conversion

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: H Hale <hhale21(at)yahoo(dot)com>
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: [GENERAL] binary timestamp conversion
Date: 2005-10-14 21:04:35
Message-ID: 7448.1129323875@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

H Hale <hhale21(at)yahoo(dot)com> writes:
> I save 1970-01-01 00:00:00 and read it back expecting
> the difference between postgres and unix epochs but
> get different results each time.

> (After conversion to host byte order).

Sounds to me like you're picking up garbage rather than the data you
should. Does your code to fetch the binary value produce correct
answers on an ordinary int8 column?

regards, tom lane

In response to

Responses

Browse pgsql-interfaces by date

  From Date Subject
Next Message Michael Fuhr 2005-10-15 03:09:26 Re: [GENERAL] binary timestamp conversion
Previous Message H Hale 2005-10-14 20:00:01 Re: [GENERAL] binary timestamp conversion