Re: range_agg
От | Paul A Jungwirth |
---|---|
Тема | Re: range_agg |
Дата | |
Msg-id | CA+renyVJuVOLP3=CaM5rQdqy6pttWQR3BrnqeP9xMjWrHaL3=Q@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: range_agg (Alvaro Herrera <alvherre@2ndquadrant.com>) |
Ответы |
Re: range_agg
|
Список | pgsql-hackers |
On Tue, Jul 23, 2019 at 3:32 PM Alvaro Herrera <alvherre@2ndquadrant.com> wrote: > Just checking if you've had a chance to make progress on this. Not a lot. :-) But I should have more time for it the next few weeks than I did the last few. I do have some code for creating concrete multirange types (used when you create a concrete range type) and filling in a TypeCacheEntry based on the range type oid---which I know is all very modest progress. I've been working on a multirange_in function and mostly just learning about Postgres varlena and TOASTed objects by reading the code for range_in & array_in. Here is something from my multirangetypes.h: /* * Multiranges are varlena objects, so must meet the varlena convention that * the first int32 of the object contains the total object size in bytes. * Be sure to use VARSIZE() and SET_VARSIZE() to access it, though! */ typedef struct { int32 vl_len_; /* varlena header (do not touch directly!) */ Oid multirangetypid; /* multirange type's own OID */ /* * Following the OID are the range objects themselves. * Note that ranges are varlena too, * depending on whether they have lower/upper bounds * and because even their base types can be varlena. * So we can't really index into this list. */ } MultirangeType; I'm working on parsing a multirange much like we parse an array, although it's a lot simpler because it's a single dimension and there are no nulls. I know that's not much to go on, but let me know if any of it worries you. :-) Paul
В списке pgsql-hackers по дате отправления: