pg.ddx.io pgsql-php@postgresql.org mailing list archive
help / color / mirror / Atom feedConverting POSTGRESQL timestamp to UNIX timestamp
3+ messages / 3 participants
[nested] [flat]
* Converting POSTGRESQL timestamp to UNIX timestamp
@ 2001-03-22 17:23 Richie <dugganr@student.cs.ucc.ie>
2001-03-22 19:33 ` Re: Converting POSTGRESQL timestamp to UNIX timestamp Dan Wilson <phpPgAdmin@acucore.com>
2001-03-26 00:11 ` Re: Converting POSTGRESQL timestamp to UNIX timestamp Grant <grant@conprojan.com.au>
0 siblings, 2 replies; 3+ messages in thread
From: Richie @ 2001-03-22 17:23 UTC (permalink / raw)
To: pgsql-php
Hi
I have a field of type timestamp in my database but when I retrieve it I
want to convert it to its unix timetamp value because I need to compare 2
tables by their timestamp value.
Any ideas how to convert PostgreSQL timestamp to Unix timestamp???
Thanks
Richie
=========================================================
Richie Duggan
Computer Science IV
University College Cork
Eamil : dugganr@student.cs.ucc.ie richie_dug@yahoo.com
Homepage : http://student.cs.ucc.ie/01/dugganr/index.html
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Converting POSTGRESQL timestamp to UNIX timestamp
2001-03-22 17:23 Converting POSTGRESQL timestamp to UNIX timestamp Richie <dugganr@student.cs.ucc.ie>
@ 2001-03-22 19:33 ` Dan Wilson <phpPgAdmin@acucore.com>
1 sibling, 0 replies; 3+ messages in thread
From: Dan Wilson @ 2001-03-22 19:33 UTC (permalink / raw)
To: Richie <dugganr@student.cs.ucc.ie>; pgsql-php
http://www.php.net/manual/en/function.strtotime.php
: Hi
:
: I have a field of type timestamp in my database but when I retrieve it I
: want to convert it to its unix timetamp value because I need to compare 2
: tables by their timestamp value.
:
: Any ideas how to convert PostgreSQL timestamp to Unix timestamp???
:
: Thanks
:
: Richie
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Converting POSTGRESQL timestamp to UNIX timestamp
2001-03-22 17:23 Converting POSTGRESQL timestamp to UNIX timestamp Richie <dugganr@student.cs.ucc.ie>
@ 2001-03-26 00:11 ` Grant <grant@conprojan.com.au>
1 sibling, 0 replies; 3+ messages in thread
From: Grant @ 2001-03-26 00:11 UTC (permalink / raw)
To: Richie <dugganr@student.cs.ucc.ie>; +Cc: pgsql-php
select date_part('epoch', timestamp(topics.date_added)) from table;
On Thu, 22 Mar 2001, Richie wrote:
> Hi
>
> I have a field of type timestamp in my database but when I retrieve it I
> want to convert it to its unix timetamp value because I need to compare 2
> tables by their timestamp value.
>
> Any ideas how to convert PostgreSQL timestamp to Unix timestamp???
>
> Thanks
>
> Richie
>
> =========================================================
> Richie Duggan
> Computer Science IV
> University College Cork
> Eamil : dugganr@student.cs.ucc.ie richie_dug@yahoo.com
> Homepage : http://student.cs.ucc.ie/01/dugganr/index.html
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo@postgresql.org so that your
> message can get through to the mailing list cleanly
>
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2001-03-26 00:11 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-03-22 17:23 Converting POSTGRESQL timestamp to UNIX timestamp Richie <dugganr@student.cs.ucc.ie>
2001-03-22 19:33 ` Dan Wilson <phpPgAdmin@acucore.com>
2001-03-26 00:11 ` Grant <grant@conprojan.com.au>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox