Re: proposal: schema PL session variables

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: proposal: schema PL session variables
Дата
Msg-id CAKFQuwbh+YBuyP_cUfw2dnLVqDD5djkEjg4BcwNhZNEReXAzWw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: proposal: schema PL session variables  (Corey Huinker <corey.huinker@gmail.com>)
Ответы Re: proposal: schema PL session variables  (Corey Huinker <corey.huinker@gmail.com>)
Re: proposal: schema PL session variables  (Pavel Stehule <pavel.stehule@gmail.com>)
Список pgsql-hackers
On Tue, Feb 9, 2016 at 11:32 AM, Corey Huinker <corey.huinker@gmail.com> wrote:

Oh, and I suggest we call them SESSION variables rather than SCHEMA variables, to reinforce the idea of how long the values in the variables live. A session variable is in a sense a 1x1 temp table, whose definition persists across sessions but whose value does not.

Of course, if they do persist across sessions, then yeah, SCHEMA makes more sense. But every package variable in Oracle PL/SQL was initialized when the package was first loaded into the session.


​The key distinction for SCHEMA was that all functions in the schema would be able to see them (and only those in the schema).

I am a bit partial, with little deep thought, to the IMPORT mechanic.  Changing them to actual session variables would be doable and you could allow for the IMPORT specification to use search_path or explicit means to locate said variables regardless of which schema​
 
​they exist in.

However, part of the goal is to blend into the broader database community and thus increase porting capabilities.  I'm not sure how well this would help fulfill that goal.

David J.

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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: Multi-tenancy with RLS
Следующее
От: Joe Conway
Дата:
Сообщение: Re: Multi-tenancy with RLS