Re: Data type confusion

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Josh Berkus" <josh(at)agliodbs(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Data type confusion
Date: 2001-08-05 22:45:20
Message-ID: 7080.997051520@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

"Josh Berkus" <josh(at)agliodbs(dot)com> writes:
> If
> INTERVAL / INTEGER = INTERVAL

Actually the operator appears to be INTERVAL / FLOAT8.

> then why does
> INTERVAL / INTERVAL = ERROR?

Because no one got around to creating an INTERVAL / INTERVAL operator.
There are plenty of such gaps in our operator set...

> Shouldn't
> INTERVAL / INTERVAL = INTEGER?

I'd think the output should be FLOAT8, myself, since the result
could be fractional.

Anyway, the generic response to such questions is "feel free to
code it up and submit a patch".

regards, tom lane

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Josh Berkus 2001-08-05 23:00:27 Re: Data type confusion
Previous Message Allan Engelhardt 2001-08-05 22:20:05 Re: Data type confusion