what the correct way to call a stored procedure withToraclequery

Henri GP

Member

I have to use procedures with the component Toraclequery,
I do not remember the way to do,
I wrote a procedure, very simple, without variable,I created the table that goes with it(found in Allroundautomation), all works well on the database and PL / SQL

The procedure in Oracle :

CREATE OR REPLACE PROCEDURE Augmentation_1
IS
Begin
Update DOA_EMP Set sal = sal * 1.2
Where empno = 7900 ;
End;

I call it inside with Oracle :

Declare
LR$Emp DOA_EMP%Rowtype ;
Begin
Select * Into LR$Emp From DOA_EMP Where empno = 7900; -- lecture ligne avant mise
 
This apparently happens on line 5, so there is some old code and you will need to clear the query before adding the lines:

Code:
with OracleQuery1 do
begin
  Clear;
  SQL.Add ('Begin');
  SQL.Add ('Augmentation_1;');
  SQL.Add ('End;');
  execute;
end;

 
Hello,

Thank you for all information,
All works well, I was not the correct shema,
Now I can run procedures and functions is well with ToracleQuery,
I am looking for other examples, some links will be welcome.

Sincerely,
Henri

 
Back
Top