Received: from mail4.mx.voyager.net (mail4.mx.voyager.net [216.93.66.203]) by postgresql.org (8.11.3/8.11.4) with ESMTP id f86446795523 for ; Thu, 6 Sep 2001 00:04:06 -0400 (EDT) (envelope-from mvincent@cablespeed.com) Received: from mitch (mdmmi022248.voyager.net [216.93.22.248] (may be forged)) by mail4.mx.voyager.net (8.10.2/8.10.2) with SMTP id f85001005382; Tue, 4 Sep 2001 20:00:01 -0400 (EDT) Message-ID: <003d01c13688$be7c8bd0$f8165dd8@mitch> From: "Mitch Vincent" To: , "Brent R. Matzelle" References: Subject: Re: Date calc/comparisions Date: Thu, 6 Sep 2001 00:01:50 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4807.1700 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4807.1700 X-Archive-Number: 200109/2 X-Sequence-Number: 523 You could do SELECT EXTRACT(EPOCH FROM ); -- To get epoch, then use PHP to do the date calculation.. You could do the calculation in the database too, though.. Check out http://postgresql.crimelabs.net/users-lounge/docs/7.1/user/functions-datetim e.html ----- Original Message ----- From: "Brent R. Matzelle" To: Sent: Wednesday, September 05, 2001 1:24 PM Subject: [PHP] Date calc/comparisions > I need to know if the date returned from a TIMESTAMP field is less than 24 hours old. > However, PHP does not understand how to compare times retrieved from PostgreSQL. > Have any of you any experience with this type of calculation? > > Thanks and warm regards, > > Brent > > > > ---------------------------(end of broadcast)--------------------------- > TIP 4: Don't 'kill -9' the postmaster >