Re: BUG #1518: Conversions to (undocumented) SQL year-month and

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Roy Badami <roy(at)gnomon(dot)org(dot)uk>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #1518: Conversions to (undocumented) SQL year-month and
Date: 2005-03-23 23:07:56
Message-ID: 15463.1111619276@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Roy Badami <roy(at)gnomon(dot)org(dot)uk> writes:
> Which is where my comment about EXTRACT comes in. They can both be
> stored as 13 months, but EXTRACT (MONTH FROM ...) should return 1
> month or 13 months as appropriate. Surely this isn't a problem, you
> know the type of the interval?

EXTRACT doesn't have access to the typmod of its input, in general.
We associate typmods with stored columns but not with the results
of arbitrary expressions.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Roy Badami 2005-03-23 23:19:07 Re: BUG #1518: Conversions to (undocumented) SQL year-month
Previous Message Bruce Momjian 2005-03-23 23:06:40 Re: BUG #1518: Conversions to (undocumented) SQL year-month