From:
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To:
Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc:
Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>,
Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>,
PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject:
Re: review: CHECK FUNCTION statement
Date:
2011-12-02 15:05:15
Message-ID:
16633.1322838315@sss.pgh.pa.us (view raw or flat )
Thread:
2011-11-26 08:51:17 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-29 12:17:01 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-11-29 14:21:55 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-29 17:15:26 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-11-29 17:37:24 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-29 18:38:28 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2011-11-29 19:37:15 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-29 19:38:06 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-30 15:23:16 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-11-30 15:53:42 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-11-30 16:03:59 from Robert Haas <robertmhaas(at)gmail(dot)com>
2011-11-30 16:13:58 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-11-30 16:09:13 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2011-11-30 16:14:25 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-30 16:19:05 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-11-30 16:39:13 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-30 16:58:46 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-11-30 18:21:54 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-30 18:30:03 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-12-02 10:14:17 from Peter Eisentraut <peter_e(at)gmx(dot)net>
2011-12-02 15:05:15 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-12-02 18:45:16 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-02 10:52:19 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-02 20:33:00 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-02 20:47:02 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-03 11:02:13 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-07 07:23:32 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-07 14:46:14 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-07 15:17:59 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-07 15:30:50 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-08 14:07:07 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-08 15:34:10 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-09 11:27:36 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-09 14:35:12 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-09 16:02:19 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-09 17:08:30 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-12 15:49:18 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-12 15:55:35 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-13 10:01:27 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-13 12:59:51 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-13 15:37:30 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-12-13 16:55:40 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-14 06:33:03 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-14 15:30:02 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-14 20:52:08 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-15 09:38:55 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-15 11:36:24 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-15 13:04:37 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-16 13:49:43 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2011-12-16 18:49:48 from Greg Smith <greg(at)2ndQuadrant(dot)com>
2011-12-17 21:00:56 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-19 14:56:25 from Greg Smith <greg(at)2ndQuadrant(dot)com>
2011-12-19 15:47:25 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-01-01 12:01:08 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-01-03 11:08:37 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2012-01-04 14:27:08 from "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
2012-01-29 13:20:00 from Petr Jelínek <pjmodos(at)pjmodos(dot)net>
2012-02-28 16:48:35 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-02-28 19:30:58 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-02-28 19:42:22 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-02-28 20:41:13 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-02-28 20:44:02 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-02-28 21:27:51 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-02-29 13:37:48 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-02-29 18:53:03 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-02-29 20:25:30 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-01 19:46:43 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-02 02:44:59 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-02 08:30:01 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-02 08:29:26 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-02 14:46:27 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-02 15:07:41 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-03 01:24:46 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-03 05:25:52 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-03 05:45:06 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-03 06:01:45 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-03 06:03:25 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-03 19:54:19 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-03 20:56:23 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-03 23:13:04 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-04 19:33:08 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-05 02:54:36 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-05 13:49:01 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-05 16:02:50 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-05 18:11:41 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-06 06:43:06 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-06 13:21:28 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-03-06 14:12:57 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-06 21:52:21 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-07 05:35:06 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-07 15:55:12 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-03-03 13:26:04 from Petr Jelínek <pjmodos(at)pjmodos(dot)net>
2012-03-03 19:42:47 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2011-12-17 20:37:36 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-12-17 21:25:02 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-30 16:06:02 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2011-11-30 18:34:07 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
2012-08-17 01:08:00 from Bruce Momjian <bruce(at)momjian(dot)us>
2012-08-17 03:51:35 from Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
Lists:
pgsql-hackers
Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> On ons, 2011-11-30 at 10:53 -0500, Tom Lane wrote:
>> I think the important point here is that we need to support more than
>> one level of validation, and that the higher levels can't really be
>> applied by default in CREATE FUNCTION because they may fail on perfectly
>> valid code.
> How would this work with anything other than PL/pgSQL in practice?
Well, that's TBD by the individual PL authors, but it hardly seems
implausible that there might be lint-like checks applicable in many
PLs. As long as we have the functionality pushed out to a PL-specific
checker function, the details can be worked out later.
> So what I'd like to have is some way to say
> check all plpythonu functions [in this schema or whatever] using
> checker "pylint"
> where "pylint" was previously defined as a checker associated with the
> plpythonu language that actually invokes some user-defined function.
That sounds like a language-specific option to me.
> Also, what kind of report does this generate?
Good question. I suspect what Pavel has now will raise errors, but that
doesn't scale very nicely to checking more than one function, or even to
finding more than one bug in a single function.
My first instinct is to say that it should work like plain EXPLAIN, ie,
deliver a textual report that we send as if it were a query result.
regards, tom lane
In response to
Responses
pgsql-hackers by date
Next :From: Tom LaneDate: 2011-12-02 15:11:19
Subject : Re: Inlining comparators as a performance optimisation
Previous :From : karavelovDate : 2011-12-02 14:23:32
Subject : Re: Why so few built-in range types?