Subject Re: [Firebird-Architect] Exec. statement parameters
Author Adriano dos Santos Fernandes
Vlad Khorsun escreveu:
>> Vlad,
>>
>> Why the new execute statement (in the separate branch) syntax has named
>> parameters using colons instead of just question marks?
>>
>> AFAIR, syntax wasn't discussed here.
>>
>
> Because it is natural way for users of how to use parameters in client applications.
> Firebird acts as client application in this case. Note, both colons and questions are
> allowed to mark parameters. What problem do you see there ?
It's natural to Delphi users, nothing in general and inconsistent with
normal client behavior.

Execute block uses question mark, normal parameters uses question mark.
But in Delphi they are replaced.

Your example also shows how confusing it is:
----------
S = 'INSERT INTO TTT VALUES (:a, :b, :a)';
EXECUTE STATEMENT (:S) (CURRENT_TRANSACTION, CURRENT_CONNECTION)
----------

Three parameters, two names, and two values...

I'm against this syntax.


Adriano