Re: [BUGS] BUG #14464: Problems about FUNCTIONS

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: [BUGS] BUG #14464: Problems about FUNCTIONS
Дата
Msg-id CAKFQuwbm7=hsuu2fH_j+nMC_Yh4KCtbz9ODDhmBhJ1hA6Dp7cA@mail.gmail.com
обсуждение исходный текст
Ответ на [BUGS] BUG #14464: Problems about FUNCTIONS  (syspegasus@gmail.com)
Список pgsql-bugs
On Tue, Dec 13, 2016 at 9:42 AM, <syspegasus@gmail.com> wrote:
The following bug has been logged on the website:

Bug reference:      14464

Hi, I'm with problems about functions.
When I execute a select with Function is very slow, and when I execute
repeating the code of the existing function inside my SQL is faster.
I need to centralize my code, because of that I'm using functions, but is
very very slow..
Please how can I use Function and become faster? I need to centralize the
SQL

This list is intended for reporting bugs in PostgreSQL.  This request for help is not that.  Please choose a more appropriate list - pgsql-general@postgresql.org suffices as a catch-all.

​That said, you'll likely find improvement by choosing the correct language to write your function in.  Namely, choose SQL unless and until you are forced to choose pl/pgsql.  As you are simply embedding a single SELECT query you do not use any features that are only present in pl/pgsql.

David J.

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

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: Re: [BUGS] BUG #14463: refcursor cann't used with array or variadic parameter?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [BUGS] BUG #14463: refcursor cann't used with array or variadic parameter?