On Feb 28, 2008, at 6:04 AM, Alban Hertroys wrote:
On Feb 27, 2008, at 3:47 PM, Bill Moran wrote:
Something like:
$ SELECT CONVERT('12 days 13 hours'::INTERVAL AS hour);
hour
--
301
$ SELECT CONVERT('6 hours 17 minutes'::INTERVAL AS hour);
hour
--
6.2833
Am I approaching this pro
On Feb 27, 2008, at 3:47 PM, Bill Moran wrote:
Something like:
$ SELECT CONVERT('12 days 13 hours'::INTERVAL AS hour);
hour
--
301
$ SELECT CONVERT('6 hours 17 minutes'::INTERVAL AS hour);
hour
--
6.2833
Am I approaching this problem wrong? or is there something out there
and my Goo
Bill Moran wrote:
> It just seemed like this would be something so common that there'd
> be something in existence already. I guess I was wrong.
Yeah, I have wished for the same thing myself.
--
Alvaro Herrerahttp://www.CommandPrompt.com/
The PostgreSQL Company
In response to Tom Lane <[EMAIL PROTECTED]>:
> Bill Moran <[EMAIL PROTECTED]> writes:
> > There seems to be a lack of useful functions for converting intervals
> > to useful representations. For example, I want to display an interval
> > in hours and fractions of hours only, not hours and minutes
Bill Moran <[EMAIL PROTECTED]> writes:
> There seems to be a lack of useful functions for converting intervals
> to useful representations. For example, I want to display an interval
> in hours and fractions of hours only, not hours and minutes.
Perhaps EXTRACT(EPOCH ...) to get total seconds and
This has come up a few times over the last few months, and I'm not
too keen on the solutions we've been using.
There seems to be a lack of useful functions for converting intervals
to useful representations. For example, I want to display an interval
in hours and fractions of hours only, not hou