|Subject||Re: [Firebird-Architect] Exec. statement parameters|
> Vlad Khorsun escreveu:EXEC BLOCK was created looking at stored procedures. I believe it have
>>> Named parameters is good feature, but what about the syntax in the sample, O
>>> also do not like it. If we use named parameters, it should be something like:
>>> S = 'INSERT INTO TTT VALUES (:a, :b, :a)';
>>> EXECUTE STATEMENT S (a=CURRENT_TRANSACTION, b=CURRENT_CONNECTION);
>> Hmm... now i see where confusion is. I'll look how to implement such syntax
> This is one of the confusions. :-)
> Note that I see no reason to reject such type of code:
> execute block
> insert into t values (?)
> I.e., have parameters direct inside EXEC. BLOCK instead of need to
> declare variables.
good syntax and it not needs to be changed. Explicitly named parameters
always better than implicit unnamed ones, i believe.
> Then imagine you use colon there. You can't know if you refer to localAs we not going to change EXEC BLOCK syntax we have no such problem
> variable or parameter. (unless we make explicit that locals variables
> have precedence)
> Oracle uses this colon syntax for names parameters, but local variablesWe also allow to use local variables without markers in many (not in all) cases
> are not accessed with it.