Re: custom index
От | Simon Riggs |
---|---|
Тема | Re: custom index |
Дата | |
Msg-id | 1267530808.20134.9723.camel@ebony обсуждение исходный текст |
Ответ на | custom index (michael uwe maier <gtrw23@web.de>) |
Список | pgsql-general |
On Mon, 2010-03-01 at 14:52 +0100, michael uwe maier wrote: > i want to develop an index for a special problem. > The postgres docs shows the necessary bits in > http://www.postgresql.org/docs/8.4/interactive/indexam.html > especially paragraph 50.2 "Index Access Method Functions". > > Now my question: can i use the (documented) Server Programming > interface within this functions (e.g. SPI_exec within ambuild) > or do i need to use other (possibly undocumented) functions. > Background: The index needs some metadata which can be created > within "normal" tables. Otherwise this information must be built > within the index. Yes. There isn't any other way to pass user-defined metadata to an index at build time. "Storage parameters" exist, but these aren't user extensible, yet. Using SQL within anything other than ambuild would cause the index to be volatile and likely to be non-useful. > And as an appendix to my question: Are there any (simple) examples > for custom indexes ? Look at hash indexes. That is somewhat simpler because of the lack of transaction logging. -- Simon Riggs www.2ndQuadrant.com
В списке pgsql-general по дате отправления: