Re: Help with CREATE FUNCTION

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: Help with CREATE FUNCTION
Дата
Msg-id CAKFQuwYW_jxGdsQzeiC2v6EX_776ducwkW-5U5Q_By9=gdewTw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Help with CREATE FUNCTION  (Kip Warner <kip@thevertigo.com>)
Ответы Re: Help with CREATE FUNCTION  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Help with CREATE FUNCTION  (Kip Warner <kip@thevertigo.com>)
Список pgsql-novice
On Monday, April 18, 2016, Kip Warner <kip@thevertigo.com> wrote:
On Mon, 2016-04-18 at 10:57 -0700, David G. Johnston wrote:
> Begin/end etc only work for pl/pgsql functions.
>
> What version of PostgreSQL?

I'm using 9.4.

> What are these supposed to represent?

They are pre-calculated constants that are part of a more complex
algorithm. I can't submit them when I install the database schema
because they may change later


So?
 
 and they make more sense to be provided
as part of the client side application's query. 

Then add three more arguments to the function and refer to those arguments like you do the two ids.

There is no provision in PostgreSQL for constructing a global variable in that fashion.  You could maybe leverage GUCs to that effect, though.


David J.

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

Предыдущее
От: Kip Warner
Дата:
Сообщение: Re: Help with CREATE FUNCTION
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Help with CREATE FUNCTION