Re: Time difference without intervals - Mailing list pgsql-sql

From Bruno Wolff III
Subject Re: Time difference without intervals
Date
Msg-id 20021109155232.GA18883@wolff.to
Whole thread Raw
In response to Re: Time difference without intervals  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-sql
On Fri, Nov 08, 2002 at 16:11:05 -0500, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Roberto Mello <rmello@cc.usu.edu> 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.


pgsql-sql by date:

Previous
From: Stephan Szabo
Date:
Subject: Re: Some more weird NULL behavior
Next
From: "Zhidian Du"
Date:
Subject: table protein does not have an attribute oid? why?