From: | "Josh Berkus" <josh(at)agliodbs(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Josh Berkus" <josh(at)agliodbs(dot)com> |
Cc: | Allan Engelhardt <allane(at)cybaea(dot)com>, pgsql-sql(at)postgresql(dot)org |
Subject: | Re: Re: Data type confusion |
Date: | 2001-08-06 21:59:00 |
Message-ID: | web-97649@davinci.ethosmedia.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
Tom,
> Curiously enough, ANSI doesn't define an INTERVAL-divided-by-INTERVAL
> function either. Also, it rather looks like ANSI adopted the
> position
> Peter E. expressed:
>
> Year-month intervals are mutually comparable only with other
> year-
> month intervals. [...]
> Day-time intervals are mutually comparable only with other
> day-
> time intervals. [...]
> Operations involving items of type datetime require that the
> date-
> time items be mutually comparable. Operations involving
> items of
> type interval require that the interval items be mutually
> compara-
> ble.
Hmmm ... does this mean that I couldn't divide '1 year' by '1 week'? I
can certaily see not allowing division of '1 year' by '28 seconds' as it
spares us a whole bunch of calendar-generated fuzziness.
It seems to me that:
years,months,weeks,days / years,months,weeks,days is OK, and
days,hours,minutes,seconds / days,hours,minutes,seconds is also easy,
but
years,months,weeks / hours,minutes,seconds is where we get in trouble.
So I propose that we suppot the first two and disallow the third.
Thus I think that we can adhere to the spec, while still providing the
functionality developers want and avoiding a whole lot of '5 months 11
minutes' type headaches.
-Josh
______AGLIO DATABASE SOLUTIONS___________________________
Josh Berkus
Complete information technology josh(at)agliodbs(dot)com
and data management solutions (415) 565-7293
for law firms, small businesses fax 621-2533
and non-profit organizations. San Francisco
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2001-08-06 22:14:30 | Re: Re: Data type confusion |
Previous Message | Tom Lane | 2001-08-06 21:50:20 | Re: Re: Data type confusion |