Re: extended operator classes vs. type interfaces

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Yeb Havinga <yebhavinga(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: extended operator classes vs. type interfaces
Date: 2010-04-15 00:48:17
Message-ID: 201004150048.o3F0mHG15943@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Robert Haas wrote:
> On Fri, Apr 9, 2010 at 11:07 AM, Yeb Havinga <yebhavinga(at)gmail(dot)com> wrote:
> >
> >> From the implementers perspective, IMHO an extra catalog entry in pg_type
> >> is not bad on its own, you would have one anyway if the range type was
> >> explicitly programmed. About different kinds of range types - I would not
> >> know how to 'promote' integer into anything else but just one kind of 'range
> >> of integer' type. So the number of extra pg_types would be more like
> >> O(number of linear ordered base types).
> >
> > .. I now see the example of different ranges in your original mail with
> > different unit increments. Making that more general so there could be
> > continuous and discrete ranges and for the latter, what would the increment
> > be.. OTOH is a range of integers with increment x a different type from
> > range of integers with increment y, if x<>y? Maybe the increment step and
> > continuous/discrete could be typmods.
>
> Nope, not enough bits available there. This is fundamentally why the
> typid/typmod system is so broken - representing a type as a fixed size
> object is extremely limiting. A fixed size object that MUST consist
> of a 32-bit unsigned OID and a 32-bit signed integer is even more
> limiting.

You mean the typmod system we developed 13 years ago needs updating?
Seems unlikely. ;-)

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2010-04-15 00:54:45 Re: Win32 timezone matching
Previous Message Robert Haas 2010-04-15 00:37:18 Re: Thoughts on pg_hba.conf rejection