Answer Posted / mk
Function:-
A function is a predefined action which can consumed so that
retrieve the information from table in various scenario .
Procedure :-
procedure are SQl and PL/SQL code compile and stored in the
database.
Difference
Procedure
It may or may Not return a value
It can return multiple value also
It has both Input & output parameter
Doesn’t uses return statement for returning a value
Output Parameter will be specify using Output Clause
This allow select as well as DML operation
It support Transaction mgmt and error-handling using TRY and
Catch Block
They can call another procedure and function for Execution
Function
Function
It Must return a value
It can return only single value
It has both Input parameter
Uses return statement for returning a value
Output Parameter will be specify using Return Clause
This allow select as statement
Doesn’t support Transaction mgmt and error-handling using
TRY and Catch Block
They can call only another function for Execution
When will use :-
We will use procedure to perform complex business Logic as
well as we use function while performing simple
mathematical calculation.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How to write a query with a right outer join in oracle?
What are the varoius components of physical database structure of oracle database?
How to upsert (update or insert into a table)?
What is the data pump export utility?
ABOUT IDENTITY?
Please explain me all types of Data models. Also give me the details if each model can have other name.for example:schematic data model is also known as conceptual data model and entity relation data model.
defination of bitmap index
What is oracle used for?
What is a data lock in oracle?
What are the original export and import utilities?
How to write a query with a left outer join in oracle?
Explain self joins in oracle?
How to get execution statistics reports on query statements?
How to bring a tablespace offline?
When do you get a .pll extension in oracle?