From: "Andrew Dunstan" on
On Sun, July 4, 2010 9:58 am, Tom Lane wrote:

>
> BTW, we intentionally didn't put any provision for parameters into DO
> originally. What's changed to alter that decision?
>

Nothing that I know of, I think there is just a little impatience here. I
think the consensus was that we needed to get some experience of DO in the
field before looking at a parameter mechanism. I still think that's the
correct position.

cheers

andrew




--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

From: Pavel Stehule on
2010/7/4 Tom Lane <tgl(a)sss.pgh.pa.us>:
> Pavel Stehule <pavel.stehule(a)gmail.com> writes:
>> my syntax is reflecting fact, so these are not true parameters - it's
>> +/- similar to default values of function parameters.
>
> FWIW, that doesn't seem like a positive to me.
>
>> You cannot to
>> write do (a int := $1) $$ ... $$ - because utils statements hasn't
>> have variables.
>
> Yet.  I don't particularly want to relax that either, but the syntax of
> this feature shouldn't assume it'll be true forever.
>
> I think it's better to not confuse these things with default parameters,
> so Florian's idea looks better to me.
>
> BTW, we intentionally didn't put any provision for parameters into DO
> originally.  What's changed to alter that decision?
>
>                        regards, tom lane
>

It just concept - nothing more. And my instinct speak so inline code
block without external parametrization is useless.

Regards

Pavel Stehule

--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

From: Pavel Stehule on
2010/7/4 Tom Lane <tgl(a)sss.pgh.pa.us>:
> Pavel Stehule <pavel.stehule(a)gmail.com> writes:
>> my syntax is reflecting fact, so these are not true parameters - it's
>> +/- similar to default values of function parameters.
>
> FWIW, that doesn't seem like a positive to me.
>
>> You cannot to
>> write do (a int := $1) $$ ... $$ - because utils statements hasn't
>> have variables.
>
> Yet.  I don't particularly want to relax that either, but the syntax of
> this feature shouldn't assume it'll be true forever.
>
> I think it's better to not confuse these things with default parameters,
> so Florian's idea looks better to me.

Maybe I am didn't explain well my idea. The most all is modificated
named notation enhanced about type info. It isn't default parameter
definition - so I use ":=" and not use "=". And it has same advantage
like named notation has. Using a keyword "USING" isn't perfectly clean
for me - I have a problem with position of parameters - but if other
people feel it different, I'll not have a problem.

do(a int := 20, b int := 20) $$ ... $$;
do (a int, b int) $$ .... $$ USING 10,20;

generally both syntaxes are used now.

This patch is just concept - I spoke it, I would to show attractive
behave, and Florian showed possible wery nice colaboration shell with
psql. I don't want to insult somebody.

Regards
Pavel Stehule



>
> BTW, we intentionally didn't put any provision for parameters into DO
> originally.  What's changed to alter that decision?
>
>                        regards, tom lane
>

--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

From: Andrew Dunstan on


Pavel Stehule wrote:
>> BTW, we intentionally didn't put any provision for parameters into DO
>> originally. What's changed to alter that decision?
>>
>>
>
> It just concept - nothing more. And my instinct speak so inline code
> block without external parametrization is useless.
>
>
>

You have said this before, IIRC, but frankly your instinct is just
wrong. It is no more useless than are parameter-less functions, and I
use those frequently. I used a DO block for some useful testing just the
other day.

This whole proposal strikes me as premature. What we need is some
experience from the field in using DO before we can sensibly decide how
it should be extended. And we won't get that until 9.0 has been released
and used for a while.

cheers

andrew

--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

From: Pavel Stehule on
2010/7/4 Andrew Dunstan <andrew(a)dunslane.net>:
>
>
> Pavel Stehule wrote:
>>>
>>> BTW, we intentionally didn't put any provision for parameters into DO
>>> originally.  What's changed to alter that decision?
>>>
>>>
>>
>> It just concept - nothing more. And my instinct speak so inline code
>> block without external parametrization is useless.
>>
>>
>>
>
> You have said this before, IIRC, but frankly your instinct is just wrong. It
> is no more useless than are parameter-less functions, and I use those
> frequently. I used a DO block for some useful testing just the other day.
>
> This whole proposal strikes me as premature. What we need is some experience
> from the field in using DO before we can sensibly decide how it should be
> extended. And we won't get that until 9.0 has been released and used for a
> while.
>

just we have different opinion

Regards

Pavel

> cheers
>
> andrew
>

--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers