Re: fomatting an interval

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Joseph Shraibman <jks(at)selectacast(dot)net>
Cc: nolan(at)celery(dot)tssi(dot)com, PostgreSQL General <pgsql-general(at)postgresql(dot)org>
Subject: Re: fomatting an interval
Date: 2003-05-13 01:09:20
Message-ID: 25315.1052788160@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

>>> How can I format an interval?

Well, there are several possibilities such as to_char() and EXTRACT()
...

> I want something like the default format but without the milliseconds.

... but for this particular problem, why not just round the given
interval to an integral number of seconds, by casting it to interval(0)?

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Joseph Shraibman 2003-05-13 01:45:33 Re: fomatting an interval
Previous Message John Pawlicki 2003-05-13 00:32:00 Problem Starting Postgresql after upgrade from SuSE8.1 to SuSE 8.2