From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com> |
Cc: | Andrew Dunstan <andrew(at)dunslane(dot)net>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Petr Jelinek <pjmodos(at)pjmodos(dot)net> |
Subject: | Re: Proposal: USING clause for DO statement |
Date: | 2009-11-21 15:48:59 |
Message-ID: | 14791.1258818539@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com> writes:
> 2009/11/21 Andrew Dunstan <andrew(at)dunslane(dot)net>:
>> One possible problem: what type would these anonymous params be?
> It is solved long time - without specification, any parameter is
> 'unknown text'.
Nonsense.
We do have the ability to infer parameter types when parsing a SQL
statement. That does not extend to any random PL being able to do it.
In fact, NONE of them can do it, not even plpgsql. They all expect
incoming parameter types to be predetermined.
Without types *and* names, there is no point in considering parameters.
And the problem with that, which is why we didn't put parameters into
DO in the first place, is that it raises the minimum notational bar
quite a lot. You might as well go ahead and define a temporary
function.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2009-11-21 15:52:14 | Re: DEFAULT of domain ignored in plpgsql (8.4.1) |
Previous Message | Andrew Dunstan | 2009-11-21 15:41:02 | Re: Proposal: USING clause for DO statement |