Error : Teste.CreateTemporary(ltClob);

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
rcdill
Posts: 3
Joined: Wed 27 Jun 2007 18:12

Error : Teste.CreateTemporary(ltClob);

Post by rcdill » Wed 27 Jun 2007 19:34

Dear friends,

We have one stored procedure in oracle (9i) for sending of emails. When the method Execute is called appears the error: "Lob Locator Should Be Inited".

The commented line ('//Teste.CreateTemporary(ltClob);') is causing an error “Function is not suported”.

Below the used code:

procedure TForm1.Button1Click(Sender: TObject);
var
Teste : TOraLob;
begin
try
Teste:=TOraLob.Create(OraSession1.OCISvcCtx);
Teste.AllocLob;
//Teste.CreateTemporary(ltClob);
Teste.LoadFromFile('C:\Arquivos de programas\Borland\Delphi5\Projects\Unit1.dfm');
OSP1.Prepare;
OSP1.ParamByName('P_FROM_NAME').Value:='[email protected]';
OSP1.ParamByName('P_TO_NAME').Value:='[email protected]';
OSP1.ParamByName('P_CC_NAME').Value:='';
OSP1.ParamByName('P_CCO_NAME').Value:='';
OSP1.ParamByName('P_SUBJECT').Value:='Teste de mensagem';
OSP1.ParamByName('P_MESSAGE').Value:='Teste de mensagem';
OSP1.ParamByName('P_ANEXO').AsOraClob:=Teste;
OSP1.Execute;
except
on E: Exception do
begin
raise Exception.Create('Erro : ' + E.message);
end;
end;
end;


If somebody will be able to help, since already is thankful.
Rcdill.

Challenger
Devart Team
Posts: 925
Joined: Thu 17 Nov 2005 10:53

Post by Challenger » Mon 02 Jul 2007 08:47

Please specify the versions of ODAC and Oracle you use.

rcdill
Posts: 3
Joined: Wed 27 Jun 2007 18:12

Post by rcdill » Mon 02 Jul 2007 11:48

Challenger wrote:Please specify the versions of ODAC and Oracle you use.
It forgives for the imperfection. The version is 5.55.0.20 - Delphi 5.

Thanks.

Challenger
Devart Team
Posts: 925
Joined: Thu 17 Nov 2005 10:53

Post by Challenger » Mon 02 Jul 2007 12:41

TOraLob.CreateTemporary with the Net option was supported in ODAC 5.55.1.24. Please install the latest build of ODAC 5. It is ODAC 5.80.0.42. You should also call the TOraLob.WriteLob method before calling the Execute method.

rcdill
Posts: 3
Joined: Wed 27 Jun 2007 18:12

Post by rcdill » Mon 02 Jul 2007 12:50

Challenger wrote:TOraLob.CreateTemporary with the Net option was supported in ODAC 5.55.1.24. Please install the latest build of ODAC 5. It is ODAC 5.80.0.42. You should also call the TOraLob.WriteLob method before calling the Execute method.
Thanks Challanger. I go to try to make this.

Post Reply