Dynamically create TOraStoredProc and overloaded function

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
gharris
Posts: 5
Joined: Mon 03 May 2010 12:22

Dynamically create TOraStoredProc and overloaded function

Post by gharris » Mon 03 May 2010 12:32

Hi

I am dynamically creating a TOraStoredProc to connect to an overloaded function and I am not getting the return value from the function (see code snippet below). Yet when I add the call to the same function on a form (i.e. I stick TOraStoreProc object on a form) it returns a value.

------%<


GetOraType := TOraStoredProc.Create(nil);
try
GetOraType.Session := FSession;
GetOraType.StoredProcName := 'SDS.CDF_FIELD.GET_ORA_TYPE';
GetOraType.Overload := 2;
GetOraType.Params.CreateParam(ftString, 'RESULT', ptOutput);
GetOraType.Params.CreateParam(ftFloat, 'MCP_ID', ptInput).Value := MCP_ID;
GetOraType.Execute;

FTranslationType := GetOraType.ParamByName('RESULT').Value;
finally
GetOraType.Free;
end;
------%<

Version of ODAC: 5.70.0.28
Oracle Version: 10.2.0.4.0
Oracle Client: 10
Delphi Version: 6 (fully patched)

TIA

Graham Harris

bork
Devart Team
Posts: 649
Joined: Fri 12 Mar 2010 07:55

Post by bork » Thu 06 May 2010 09:50

Hello

Please do not duplicate topics. We have answered you in other thread.

Post Reply