Re: Assertions in PL/PgSQL

Поиск
Список
Период
Сортировка
Искать
От
Jaime Casanova
Тема
Re: Assertions in PL/PgSQL
Дата
Msg-id
CAJKUy5g-VCMF65JDuCnxdSYWLr5SJEROqvtuGd_+eiE+2dDnbg@mail.gmail.com
Ответ на
Список
Дерево обсуждения
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>


El 14/09/2013 15:18, "Marko Tiikkaja" <marko@joh.to> escribió:
>
> On 2013-09-14 21:55, Jaime Casanova wrote:
>>
>> On Sat, Sep 14, 2013 at 1:52 PM, Marko Tiikkaja <marko@joh.to> wrote:
>>>
>>> And by "compile time" here, I mean at the time when the PL/PgSQL function
>>
>> is
>>>
>>> compiled, not the postgres server binary.
>>>
>>
>> and "compile time" means when the function is created or replaced? or the
>> first time is used?
>
>
> Uhh..  I have to admit, I'm not sure.  I think this would be when you CREATE the function for the backend that created the function, and on the first call in other backends.
>
>
>> if the second. Why not have a plpgsql.enable_assert variable?
>> A directive you can use per function
>>
>> then i can keep the ASSERT and activate them by replacing the function
>
>
> The patch supports a "compiler option" to override the global option and enable it per function:
>
> create function foof()
> returns void
> as $$
> #enable_assertions
> begin
> -- failure
> assert 1 > 2;
> end
> $$ language plpgsql;
>
>
> Does this address your wishes?
>
>

That's exactly what i wanted. thanks

--
Jaime Casanova
2ndQuadrant: Your PostgreSQL partner

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