Re: Assertions in PL/PgSQL

Поиск
Список
Период
Сортировка
Искать
От
Marko Tiikkaja
Тема
Re: Assertions in PL/PgSQL
Дата
Msg-id
52400605.6010706@joh.to
Ответ на
Список
Дерево обсуждения
Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Peter Eisentraut <peter_e@gmx.net>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Peter Eisentraut <peter_e@gmx.net>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Jaime Casanova <jaime@2ndquadrant.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Jaime Casanova <jaime@2ndquadrant.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Robert Haas <robertmhaas@gmail.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Robert Haas <robertmhaas@gmail.com>
Re: Assertions in PL/PgSQL Hannu Krosing <hannu@2ndQuadrant.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Alvaro Herrera <alvherre@2ndquadrant.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Jim Nasby <jim@nasby.net>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Jim Nasby <jim@nasby.net>
Re: Assertions in PL/PgSQL Jaime Casanova <jaime@2ndquadrant.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Amit Khandekar <amit.khandekar@enterprisedb.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Jaime Casanova <jaime@2ndquadrant.com>
Re: Assertions in PL/PgSQL Jaime Casanova <jaime@2ndquadrant.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Andres Freund <andres@2ndquadrant.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Amit Khandekar <amit.khandekar@enterprisedb.com>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Marko Tiikkaja <marko@joh.to>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Amit Khandekar <amit.khandekar@enterprisedb.com>
Re: Assertions in PL/PgSQL Robert Haas <robertmhaas@gmail.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Peter Eisentraut <peter_e@gmx.net>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Tom Lane <tgl@sss.pgh.pa.us>
Re: Assertions in PL/PgSQL Robert Haas <robertmhaas@gmail.com>
Re: Assertions in PL/PgSQL Peter Eisentraut <peter_e@gmx.net>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Robert Haas <robertmhaas@gmail.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Pavel Stehule <pavel.stehule@gmail.com>
Re: Assertions in PL/PgSQL Robert Haas <robertmhaas@gmail.com>
Re: Assertions in PL/PgSQL Jaime Casanova <jaime@2ndquadrant.com>
On 9/23/13 11:01 AM, Amit Khandekar wrote:
> The assert levels sound a bit like a user might be confused by these levels
> being present at both places: In the RAISE syntax itself, and the assert
> GUC level. But  I like the syntax. How about keeping the ASSERT keyword
> optional ? When we have WHEN, we anyway mean that we ware asserting that
> this condition must be true. So something like this :
>
> RAISE [ level ] 'format' [, expression [, ... ]] [ USING option =
> expression [, ... ] ];
> RAISE [ level ] condition_name [ USING option = expression [, ... ] ];
> RAISE [ level ] SQLSTATE 'sqlstate' [ USING option = expression [, ... ] ];
> RAISE [ level ] USING option = expression [, ... ];
> *RAISE [ ASSERT ] WHEN bool_expression;*
> RAISE ;

I'd expect RAISE .. WHEN ..;  to be the same as:
  IF .. THEN    RAISE;  END IF;

i.e. in conditionally raise the caught exception in an exception 
handler.  So I'd say making the ASSERT keyword optional here would be 
very confusing.


Regards,
Marko Tiikkaja


В списке pgsql-hackers по дате отправления
От: Pavel Stehule
Дата:
Сообщение: Re: Assertions in PL/PgSQL
От: Marko Tiikkaja
Дата:
Сообщение: Re: Assertions in PL/PgSQL
FAQ