Beruflich Dokumente
Kultur Dokumente
-syntax:
Is/as
Begin
Exception
End <procedure-name>;
-execute <procedure-name>;
Parameter type:
Exec proc_cust_2;
Procedure created.
customer Information
customer Name :BBB
customer Id :2
customer Addr :Baramati
is
begin
end;
1. positional notation:
exec pro_insert_cust(8,'Sanjana','Daund')
2. named notations :
exec pro_insert_cust(v_cno=>8, v_cname=>'Sanjana',
v_city=>'Daund')
3. mixed notations:
2. Out parameter:
- Shows output
- It is like variable
- Syntax:
(Para-name out datatype)
/*output
1. Using bind variable
SQL> variable z number;
SQL> exec pro_square(9,:z);
SQL> print z;
Z
----------
81
DECLARE
x number :=&number;
y number;
BEGIN
pro_square(x,y);
DBMS_OUTPUT.PUT_LINE('Square of '||x||' : '||y);
END;
/
Enter value for number: 9
old 2: x number :=&number;
new 2: x number :=9;
Square of 9: 81
3. In out parameter
- It behaves like constant at parameter level
- It behaves like variable inside procedure block