Re: Assertions in PL/PgSQL

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: Assertions in PL/PgSQL
Дата
Msg-id CAFj8pRAxJHY9+5p9=YFbyAwLBK9WA4pXMBX062v-2Txj+YpOMg@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Assertions in PL/PgSQL  (Marko Tiikkaja <marko@joh.to>)
Список pgsql-hackers



2013/9/19 Marko Tiikkaja <marko@joh.to>
On 9/19/13 2:08 PM, Pavel Stehule wrote:
I think so similar frameworks will be exists (we have some similar
Probably You and me have a same opinion so only simple and very primitive
assert is not enough:

I see as useful feature for assertions:

a) possibility to specify a message (two parametric assert)
b) possibility to specify some threshold
c) possibility to specify some level (exception, warning, notice) ..
default should be exception
c) possibility to specify a handled/unhandled exception

I think these are all neat ideas on how to further improve this feature.  I'd like to see at least a) in 9.4, but I haven't yet looked at how it could be implemented.

Not all must be implemented in 9.4, although it is +/- only exception parametrization - not hard for implementation.

But syntax should be prepared for this functionality (or should be extensible as minimum) before. Bison parser is not friendly for additional extending :( - and we can break a future extending simply just only on syntax level with bad design now. It is reason, why I am doing noise here. I remember relatively difficult extending of RAISE statement.

Regards

Pavel

 


Regards,
Marko Tiikkaja

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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: record identical operator
Следующее
От: Andres Freund
Дата:
Сообщение: Re: Freezing without write I/O