Re: ToDo: fast update of arrays with fixed length fields for PL/pgSQL

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: ToDo: fast update of arrays with fixed length fields for PL/pgSQL
Дата
Msg-id CAFj8pRDxCGTZbFJ4CM2v+PS4OTy9Co9d2prwW407kYU9KdLbUQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: ToDo: fast update of arrays with fixed length fields for PL/pgSQL  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: ToDo: fast update of arrays with fixed length fields for PL/pgSQL  (Pavel Stehule <pavel.stehule@gmail.com>)
Список pgsql-hackers



2013/10/3 Tom Lane <tgl@sss.pgh.pa.us>
Pavel Stehule <pavel.stehule@gmail.com> writes:
> If you can do a update of some array in plpgsql now, then you have to work
> with local copy only. It is a necessary precondition, and I am think it is
> valid.

If the proposal only relates to assignments to elements of plpgsql local
variables, it's probably safe, but it's also probably not of much value.
plpgsql has enough overhead that I'm doubting you'd get much real-world
speedup.  I'm also not very excited about putting even more low-level
knowledge about array representation into plpgsql.

I looked to code, and I am thinking so this can be done inside array related routines. We just have to signalize request for inplace update (if we have a local copy).

I have not idea, how significant speedup can be (if any), but current behave is not friendly (and for multidimensional arrays there are no workaround), so it is interesting way - and long time I though about some similar optimization.

Regards

Pavel
 

                        regards, tom lane

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: ToDo: fast update of arrays with fixed length fields for PL/pgSQL
Следующее
От: Heikki Linnakangas
Дата:
Сообщение: Re: SSI freezing bug