Re: Range types
От | Dimitri Fontaine |
---|---|
Тема | Re: Range types |
Дата | |
Msg-id | 87fx7d7lri.fsf@hi-media-techno.com обсуждение исходный текст |
Ответ на | Range types (Scott Bailey <artacus@comcast.net>) |
Список | pgsql-hackers |
Scott Bailey <artacus@comcast.net> writes: > So basically I have an anyrange pseudo type with the functions prev, next, > last, etc defined. So instead of hard coding range types, we would allow the > user to define their own range types. Basically if we are able to determine > the previous and next values of the base types we'd be able to define a > range type. I'm envisioning in a manner much like defining an enum > type. It's not clear how to define those functions for the prefix_range datatype, where '123' represents any text begining with those chars and '123[4-6]' any text begining with '123' then either 4, 5 or 6. What's supposed to return SELECT next('123'::prefix_range); ? Regards, -- dim PS: as I'm used to use that in the telephony context, the example contain figures, but it's a text based type and given questions and reports in pgsql-general, people do use it with text ranges too.
В списке pgsql-hackers по дате отправления: