How to return more than one value from a function?
Answer Posted / alok sinha
Hello Boyz !!
Get excited to see this example thru
declare
--
varx1 number := 0;
varx2 number := 0;
varx3 number := 3;
--
begin
--
--
dbms_output.put_line('In: Varx #1 : initial value :: ' ||
varx1);
dbms_output.put_line('In: Varx #2 : initial value :: ' ||
varx2);
--
dbms_output.put_line('In: Varx #3 : Initial value :: ' ||
varx3);
dbms_output.put_line('
');
dbms_output.put_line('Hhhmmmnnn
Hhhmmmnnn Hhhmmmnnn ');
dbms_output.put_line('
');
--
--
varx3 := xx_func(varx3, varx1, varx2);
--
--
dbms_output.put_line('------------------------------------
--------------');
dbms_output.put_line('---------- Post Function -----------
------');
dbms_output.put_line('------------------------------------
--------------');
dbms_output.put_line('
');
dbms_output.put_line('------------------------------------
--------------');
dbms_output.put_line('Return Value :: Varx #3 :: returned
from function :: '|| varx3);
dbms_output.put_line('Out: Varx #1 : returned from
function :: '|| varx1);
dbms_output.put_line('Out: Varx #2 : returned from
function :: '|| varx2);
--
end;
create or replace function xx_func(north in number, east in
out number, west in out number ) return number is
south number;
begin
south := north + 4;
east := 4;
west := 5;
--
return south;
end xx_func;
| Is This Answer Correct ? | 8 Yes | 2 No |
Post New Answer View All Answers
What is hibernate and its relation to sql?
what is clause? : Sql dba
What is keys and its types?
Why do we use joins?
What information is needed to connect sql*plus an oracle server?
What is the maximum number of columns in sql table?
what is the use of double ampersand (&&) in sql queries?
what is a scheduled jobs or what is a scheduled tasks? : Sql dba
What are database links used for?
What is column?
Why are sql stored procedures used?
What is %s in sql?
How to write a single statement that concatenates the words ?hello? And ?world? And assign it in a variable named greeting?
What is the largest value that can be stored in a byte data field?
Explain commit, rollback and savepoint.