Re: [HACKERS] proposal: session server side variables
От | Pavel Stehule |
---|---|
Тема | Re: [HACKERS] proposal: session server side variables |
Дата | |
Msg-id | CAFj8pRA+2fB=j-4svZ0E8u4tk2T0ZW0w_xB+v7jD2Zkq+ddFvw@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: [HACKERS] proposal: session server side variables (Fabien COELHO <coelho@cri.ensmp.fr>) |
Ответы |
Re: [HACKERS] proposal: session server side variables
Re: [HACKERS] proposal: session server side variables |
Список | pgsql-hackers |
2017-01-04 9:56 GMT+01:00 Fabien COELHO <coelho@cri.ensmp.fr>:
With respect, I don't share your opinion - it is not enough for usage like
package variables - there usually should not to use any dependency on
transactions.
I'm not sure I understand your point. If Oracle provides unsafe package variables that can fool auditors, it is not a sufficient reason for Pg to provide the same doubtful feature. And if they have sub-transactions then their feature may not necessarily be unsafe, at least if the coding is careful, but this point does not apply to pg.
unsafe is wrong word - are you first man, what I know who are expecting transactions from variables - the variables are coming from procedural world - there are not transactions.
your mental model about variables is pretty artificial - it is strange so Oracle, MSSQL, DB2 30 years didn't find so variables should be transactional.
I agree, so there can be some advantages - but I disagree so transactional is major and required feature. There are possible artefacts on border transactional and untransactional world - so developer should to use patterns that reduces negative impacts of these artefacts.
More it is dynamic - it should be hard inconsistency to implement CREATE or
DECLARE statement for GUC. So it is out my proposal (and my goal).
I have added a few questions/remarks about your updated proposal in the wiki. Feel free to update/answer/discuss these.
I have also updated and simplified the "simple session variable" description, because now I'm convinced that they must be transactional, and that a distinct declaration statement is a pain.
I respect your opinion and don't agree with it.
Regards
Pavel
--
Fabien.
В списке pgsql-hackers по дате отправления: