Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id E2F52475EF9 for ; Sat, 9 Nov 2002 10:42:50 -0500 (EST) Received: from wolff.to (unknown [66.93.197.35]) by postgresql.org (Postfix) with SMTP id 60BA4475E5E for ; Sat, 9 Nov 2002 10:42:49 -0500 (EST) Received: (qmail 18941 invoked by uid 500); 9 Nov 2002 15:52:32 -0000 Date: Sat, 9 Nov 2002 09:52:32 -0600 From: Bruno Wolff III To: Tom Lane Cc: Roberto Mello , pgsql-sql@postgresql.org Subject: Re: Time difference without intervals Message-ID: <20021109155232.GA18883@wolff.to> Mail-Followup-To: Tom Lane , Roberto Mello , pgsql-sql@postgresql.org References: <20021108182002.GC25961@cc.usu.edu> <27705.1036789865@sss.pgh.pa.us> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <27705.1036789865@sss.pgh.pa.us> User-Agent: Mutt/1.3.25i X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200211/154 X-Sequence-Number: 10296 On Fri, Nov 08, 2002 at 16:11:05 -0500, Tom Lane wrote: > Roberto Mello writes: > > Is there any way to make a timestamp difference operation not return an > > interval? I'd like to get hours, minutes and seconds only, not the "1 day" > > or whatnot. > > I think your complaint is not that you get an interval, but that you > want it displayed differently. See to_char() ... I looked at to_char before suggesting extract. The problem is that to_char will only return hours modulo days. His question implied that he was going to have intervals longer than a day, so I don't believe to_char will work.