Procedure Using Multiple OUT mood parameter .
Watching this 10 steps of a PL/SQL Procedure you can very easily understand and memorize a Procedure format.
2. (e_id in number, f_na out varchar2, l_na out varchar2) --(Parameter Using IN/ OUT )
3. declare --(if needed)
3. IS --(IS/AS)
4. begin --(Execution)
5. select first_name, last_name /*5.1 */ into f_na, l_na --(Passing value into the variable using INTO )
from employees
where employee_id=e_id ;
6.exception ; --(Exception if needed with ;)
7. end ; --(End with ;)
EXECUTE:
declare
f varchar2(50);
la varchar2(50);
begin
P_emp_name(100,f,la);
dbms_output.put_line('Name:' || f || ' ' || la);
end;
/
Remember There are 10 Step in a Function
No comments:
Post a Comment