What are main difference between Stored Procedure and
Functions.
Answer Posted / abhirup roy
In The above answers all the major differences have been disclosed, with one wrong information.
We can call a procedure from a function and vice-versa (as long as the function and procedure has same/similar scope).
In order to defend my point I am posting one small code below for reference.
DECLARE
PROCEDURE my_proc;
FUNCTION my_func RETURN NUMBER IS
BEGIN
my_proc;
RETURN -003;
END my_func;
PROCEDURE my_proc IS
BEGIN
DBMS_OUTPUT.PUT_LINE('22');
END my_proc;
BEGIN -- main
DBMS_OUTPUT.PUT_LINE(my_func);
END;
-- IT WILL WORK FOR EVERY OCCURRENCE --
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
how to make an oracle object
Assuming today is Monday, how would you use the DBMS_JOB package to schedule the execution of a given procedure owned by SCOTT to start Wednesday at 9AM and to run subsequently every other day at 2AM.
What is ceil and floor in oracle?
How to define a cusotmer as a supplier in ORACLE R12
Can you tell me how to add new column in existing views?how?How is possible?
How i can handle exception in large code like 1000 line without distrubing the code or without exception handler sction?
What do you mean by a database transaction & what all tcl statements are available in oracle?
What is data type in oracle?
What is dynamic proxy?
What is data block in Oracle?
How to define a specific record type?
What is oracle update statement with inner join ?
What are a collation and state the different types of collation sensitivity?
How many types of synonyms in Oracle?
How to get a create statement for an existing table?