Re: Consistency problem with unlabeled intervals - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Consistency problem with unlabeled intervals
Date
Msg-id 2897.1020391306@sss.pgh.pa.us
Whole thread Raw
In response to Re: Consistency problem with unlabeled intervals  (Thomas Lockhart <lockhart@fourpalms.org>)
List pgsql-hackers
Thomas Lockhart <lockhart@fourpalms.org> writes:
>> That is, '60' is read as so many hours, '1.5' is read as so many
>> seconds.  This seems a tad inconsistent.

> They fulfill two separate use cases. Time zones can now be specified as
> intervals, and the default unit must be hours. A number with a decimal
> point is usually in units of seconds, and matches past behavior afaik.

Hm.  Well, if this behavior is intentional, it'd be nice to document it.
The existing paragraphs about interval's I/O format don't mention
behavior for unitless numbers at all, much less explain that a decimal
point has semantic significance.
        regards, tom lane


pgsql-hackers by date:

Previous
From: mlw
Date:
Subject: Re: PostgreSQL mission statement?
Next
From: Jim Mercer
Date:
Subject: Re: PostgreSQL mission statement?