| From: | James David Smith <james(dot)david(dot)smith(at)gmail(dot)com> |
|---|---|
| To: | Greg Sabino Mullane <greg(at)turnstep(dot)com> |
| Cc: | pgsql-novice(at)postgresql(dot)org |
| Subject: | Re: Datetime stored in bigint |
| Date: | 2011-07-15 23:37:24 |
| Message-ID: | CAMu32ACwT9j7dsH=EKK2NJWfko_4=iKpaGKtGATBRFTz_YyQxg@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-novice |
Maybe have a good read through here too Greg:
http://www.postgresql.org/docs/8.1/static/functions-datetime.html
James
On 15 July 2011 22:13, Greg Sabino Mullane <greg(at)turnstep(dot)com> wrote:
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: RIPEMD160
>
>
>> We have a program store into postgres database as UTF-8 format
>> i need to convert this value from 634301616478281250 to
>> date time format.
>
> You'll have to tell us where you are getting that number from,
> and (possibly) what timestamp it should map to. From the size of it,
> I would guess it's the number of nanoseconds since some point of time.
>
> The point in time it's coming from may be 1970-01-01, 1900-01-01,
> or something else (e.g. 1601-01-01). (Different computer systems
> store time differently). If it's the standard Unix epoch (1970)
> that corresponds to February 1990, if that helps.
>
> - --
> Greg Sabino Mullane greg(at)turnstep(dot)com
> End Point Corporation http://www.endpoint.com/
> PGP Key: 0x14964AC8 201107151645
> http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8
> -----BEGIN PGP SIGNATURE-----
>
> iEYEAREDAAYFAk4grUUACgkQvJuQZxSWSsgiiQCfV64u4quKX7CMGGNccy4TK394
> 2/QAoLB+ExRqYDJEGdyPxAyVkUa5yOO3
> =Rc2q
> -----END PGP SIGNATURE-----
>
>
>
> --
> Sent via pgsql-novice mailing list (pgsql-novice(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-novice
>
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Roy's Email | 2011-07-16 03:43:41 | Julian date output? |
| Previous Message | Greg Sabino Mullane | 2011-07-15 21:13:05 | Re: Datetime stored in bigint |