Hello,
How does the ProcNamedParams option works in TOraStoredProc?
I did not find in the documentation.
Tks!!
Option ProcNamedParams in TOraStoredProc
Re: Option ProcNamedParams in TOraStoredProc
The OraStoredProc.Options.ProcNamedParams option is required for using Positional or Named parameter Notation when calling a stored PL/SQL object. Thus, when OraStoredProc.Options.ProcNamedParams = False Positional Notation will be used :
begin
NULLPROC(:PARAM1, :PARAM2);
end;
When OraStoredProc.Options.ProcNamedParams = True, the call will be as follows :
begin
NULLPROC(PARAM1 => :PARAM1, PARAM2 => :PARAM2);
end;
We will describe the behavior of the OraStoredProc.Options.ProcNamedParams option in our documentation in the next build of our product.
Code: Select all
...
OraSession.ExecSQL('CREATE OR REPLACE PROCEDURE NULLPROC(PARAM1 IN VARCHAR2, PARAM2 OUT INTEGER) IS BEGIN NULL; END NULLPROC;');
OraStoredProc.Options.ProcNamedParams := False;
OraStoredProc.StoredProcName := 'NULLPROC';
OraStoredProc.Execute;
...
NULLPROC(:PARAM1, :PARAM2);
end;
When OraStoredProc.Options.ProcNamedParams = True, the call will be as follows :
begin
NULLPROC(PARAM1 => :PARAM1, PARAM2 => :PARAM2);
end;
We will describe the behavior of the OraStoredProc.Options.ProcNamedParams option in our documentation in the next build of our product.