calling a stored procedure and handling the output

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
redbull
Posts: 1
Joined: Thu 15 Dec 2005 12:28

calling a stored procedure and handling the output

Post by redbull » Thu 15 Dec 2005 12:50

Hi

I call the following procedure example:

call test_insert('bob','davis','plumber','nottingham','van',:msg,:val)

by using the Oraquery1.sql.text and then run oraquery1.execute.

How can I get the return values?

The above could be called more then 100 times in one function operation whilst it adds more users. When I have tried calling this, after about 5th or 6th iteration an access violation occurs. Removing the outputs from the stored procedure allowed the whole process to work correctly.

Unfortunately I need to get the response back from the procedure to see if it is completed successfully and identify if any errors have been captured.

The access violation only appears if the stored procedure has out parameters. Its seems that some buffer increases in size as the call is processed on each iteration, to the point exceeds its memory allocation.

I would appreciate any help on this matter.

1. Correctly call a stored procedure that has both in & out Parameters
2. Retrieve the values from the out parameters
3. Cleaning up correctly before the next iteration

Thanks in advance.

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

Post by Challenger » Thu 15 Dec 2005 14:11

Please send to ODAC support address small sample to demonstrate this problem and include script to create server objects.

Post Reply