Re: proposal: plpgsql - Assert statement
От
Marko Tiikkaja
Тема
Re: proposal: plpgsql - Assert statement
Дата
Msg-id
5409754C.1010909@joh.to
Ответ на
Re: proposal: plpgsql - Assert statement (Pavel Stehule)
Список
Дерево обсуждения
proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Craig Ringer <craig@2ndquadrant.com>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Jan Wieck <jan@wi3ck.info>
Re: proposal: plpgsql - Assert statement Alvaro Herrera <alvherre@2ndquadrant.com>
Re: proposal: plpgsql - Assert statement Peter Eisentraut <peter_e@gmx.net>
Re: proposal: plpgsql - Assert statement Peter Eisentraut <peter_e@gmx.net>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Peter Eisentraut <peter_e@gmx.net>
Re: proposal: plpgsql - Assert statement Jan Wieck <jan@wi3ck.info>
Re: proposal: plpgsql - Assert statement Jim Nasby <jim@nasby.net>
Re: proposal: plpgsql - Assert statement Ali Akbar <the.apaan@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Jan Wieck <jan@wi3ck.info>
Re: proposal: plpgsql - Assert statement Petr Jelinek <petr@2ndquadrant.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Robert Haas <robertmhaas@gmail.com>
Re: proposal: plpgsql - Assert statement Craig Ringer <craig@2ndquadrant.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Petr Jelinek <petr@2ndquadrant.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Petr Jelinek <petr@2ndquadrant.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Simon Riggs <simon@2ndQuadrant.com>
Re: proposal: plpgsql - Assert statement Jim Nasby <Jim.Nasby@BlueTreble.com>
Re: proposal: plpgsql - Assert statement Simon Riggs <simon@2ndQuadrant.com>
Re: proposal: plpgsql - Assert statement Andrew Dunstan <andrew@dunslane.net>
Re: proposal: plpgsql - Assert statement Jim Nasby <Jim.Nasby@BlueTreble.com>
Re: proposal: plpgsql - Assert statement Andrew Dunstan <andrew@dunslane.net>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Petr Jelinek <petr@2ndquadrant.com>
Re: proposal: plpgsql - Assert statement Simon Riggs <simon@2ndQuadrant.com>
Re: proposal: plpgsql - Assert statement Andrew Dunstan <andrew@dunslane.net>
Re: proposal: plpgsql - Assert statement Tom Lane <tgl@sss.pgh.pa.us>
Re: proposal: plpgsql - Assert statement Robert Haas <robertmhaas@gmail.com>
Re: proposal: plpgsql - Assert statement Tom Lane <tgl@sss.pgh.pa.us>
Re: proposal: plpgsql - Assert statement Robert Haas <robertmhaas@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Tom Lane <tgl@sss.pgh.pa.us>
Re: proposal: plpgsql - Assert statement Tom Lane <tgl@sss.pgh.pa.us>
Re: proposal: plpgsql - Assert statement Robert Haas <robertmhaas@gmail.com>
Re: proposal: plpgsql - Assert statement Tom Lane <tgl@sss.pgh.pa.us>
Re: proposal: plpgsql - Assert statement Robert Haas <robertmhaas@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Marko Tiikkaja <marko@joh.to>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Alvaro Herrera <alvherre@2ndquadrant.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Jim Nasby <Jim.Nasby@BlueTreble.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Jim Nasby <Jim.Nasby@BlueTreble.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Jim Nasby <Jim.Nasby@BlueTreble.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Tom Lane <tgl@sss.pgh.pa.us>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Jim Nasby <Jim.Nasby@BlueTreble.com>
Re: proposal: plpgsql - Assert statement Tom Lane <tgl@sss.pgh.pa.us>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Jim Nasby <decibel@decibel.org>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Tom Lane <tgl@sss.pgh.pa.us>
Re: proposal: plpgsql - Assert statement Simon Riggs <simon@2ndQuadrant.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Mike Blackwell <mike.blackwell@rrd.com>
Re: proposal: plpgsql - Assert statement Andrew Dunstan <andrew@dunslane.net>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Simon Riggs <simon@2ndQuadrant.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
Re: proposal: plpgsql - Assert statement Pavel Stehule <pavel.stehule@gmail.com>
On 9/5/14 10:09 AM, Pavel Stehule wrote:
>> I think this could still be parsed correctly, though I'm not 100% sure on
>> that:
>>
>> ASSERT WARNING (EXISTS(SELECT ..)), 'data are there';
>>
>
> PLpgSQL uses a ';' or some plpgsql keyword as SQL statement delimiter. It
> reason why RETURN QUERY ... ';' So in this case can practical to place SQL
> statement on the end of plpgsql statement.
*shrug* There are lots of cases where a comma is used as well, e.g.
RAISE NOTICE '..', , ;
> parenthesis are not practical, because it is hard to identify bug ..
I don't see why. The PL/PgSQL SQL parser goes to great lengths to
identify unmatched parenthesis. But the parens probably aren't
necessary in the first place; you could just omit them and keep parsing
until the next comma AFAICT. So the syntax would be:
RAISE [ NOTICE | WARNING | EXCEPTION/ASSERT/WHATEVER ]
boolean_expr [, error_message [, error_message_param [, ... ] ] ];
> A simplicity of integration SQL and PLpgSQL is in using "smart" keywords -
> It is more verbose, and it allow to well diagnostics
I disagree. The new keywords provide nothing of value here. They even
encourage the use of quirky syntax in *exchange* for verbosity ("IS NOT
NULL pk"? really?).
.marko
В списке pgsql-hackers по дате отправления