This question answers about calling an Oracle stored procedure: How to execute an oracle stored procedure?
However I have a procedure which takes one IN and one OUT parameter. What should my test syntax in Oracle SQL Developer look like to define a variable, run a stored procedure, and output the result of that variable?
I'm trying this but declaring the variable gives me an error:
begin
xyz MY_TABLE.EMAIL_ADDRESS%TYPE := NULL;
myPackage.GetEmailForId('12345',xyz);
end;
declare
xyz MY_TABLE.EMAIL_ADDRESS%TYPE;
begin
myPackage.GetEmailForId('12345',xyz);
dbms_output.put_line(xyz);
end;
What should my test syntax in Oracle SQL Developer look like to define a variable, run a stored procedure, and output the result of that variable?
Create a unit test.
Tools
> Unit Test
> Select Current Repository
and follow the prompts to set up a unit test repository. View
> Unit Test
to open the Unit Testing view. Create test
. Create single with dummy implementation
then click Next
. Finish
. Unit Test
view and you can right-click and select Run Test
.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.