From owner-freebsd-questions Mon Nov 19 1:28:40 2001 Delivered-To: freebsd-questions@freebsd.org Received: from anchor-post-32.mail.demon.net (anchor-post-32.mail.demon.net [194.217.242.90]) by hub.freebsd.org (Postfix) with ESMTP id 8F03837B416 for ; Mon, 19 Nov 2001 01:28:36 -0800 (PST) Received: from claycross.demon.co.uk ([194.222.107.197] helo=mail.claycrossbs.co.uk) by anchor-post-32.mail.demon.net with esmtp (Exim 2.12 #1) id 165kjC-000JaH-0W; Mon, 19 Nov 2001 09:28:35 +0000 Received: from netops (netops.claycrossbs.co.uk [192.3.6.101]) by mail.claycrossbs.co.uk (Postfix) with SMTP id 99FB132A33; Mon, 19 Nov 2001 09:28:35 +0000 (GMT) From: "Simon Griffiths" To: "Chris Aitken" , Subject: RE: Epoch Time on Freebsd with perl Date: Mon, 19 Nov 2001 09:28:49 -0000 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2911.0) In-Reply-To: <5.1.0.14.2.20011119163225.01f5b130@mail.ideal.net.au> X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 Importance: Normal Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi > [mailto:owner-freebsd-questions@FreeBSD.ORG]On Behalf Of Chris Aitken > Sent: 19 November 2001 05:37 > Subject: Epoch Time on Freebsd with perl > > > Hi all, [snip] > > $date1 = "2001-10-01 01:00:00"; > $date2 = "2001-10-01 03:00:00"; > > What I want is to somehow calculate that there is 2 hours between these 2 > dates (or 120 minutes, or 7200 seconds etc etc) > Any help on this would be appreciated. Depending on your database you could do this in SQL, I would recommend RTFMing its docs. > Cheers > > > Chris Si. -- Simon Griffiths Systems Administrator - Clay Cross Building Society Tel:+44(0)1246 862120 - Fax: +44(0)1246 250397 -- "If you give a million monkeys root access to your systems, they sure as hell aren't going to be writing any Shakespeare..." To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message