Re: Best way to convert PG's TIMESTAMPTZ to PHP DATE?

From: "David Busby" <busby(at)pnts(dot)com>
To: "Michael Hanna" <zen(at)hwcn(dot)org>, <pgsql-php(at)postgresql(dot)org>
Subject: Re: Best way to convert PG's TIMESTAMPTZ to PHP DATE?
Date: 2003-06-30 20:06:16
Message-ID: 028801c33f43$184e28c0$1100000a@busbydev
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-php

Both of these work OK for me

date('r',strtotime($record->date_field));

or

select to_char(date_field,'FORMAT SPEC') as date_field, column_two,
column_three from x where y=z

/B

----- Original Message -----
From: "Michael Hanna" <zen(at)hwcn(dot)org>
To: <pgsql-php(at)postgresql(dot)org>
Sent: Monday, June 30, 2003 12:54
Subject: [PHP] Best way to convert PG's TIMESTAMPTZ to PHP DATE?

> Anybody have any advice on this..
> Michael
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 8: explain analyze is your friend
>

In response to

Responses

Browse pgsql-php by date

  From Date Subject
Next Message Jeff 2003-06-30 21:27:01 Re: Best way to convert PG's TIMESTAMPTZ to PHP DATE?
Previous Message Michael Hanna 2003-06-30 19:54:22 Best way to convert PG's TIMESTAMPTZ to PHP DATE?