difference between stored procedure and function?

Answers were Sorted based on User's Feedback



difference between stored procedure and function?..

Answer / m m naidu

A Procedure is a sub-program that performs a specific
action.

A Procedure can be called from PL/SQL Block or from another
Procedure also.


A function is very similar to a Procedure. Both take
arguments, which can be of different modes. Both are
different forms of PL/SQL blocks. Both can be stored in the
database.
A procedure call is a PL/SQL statement by itself, while a
Function call is called as part of an expression. And a
Function must return

Is This Answer Correct ?    7 Yes 0 No

difference between stored procedure and function?..

Answer / vsandhyana

Function can call anywhere in your select query but store
procedure cannot call from the select statement.

store procedure may or may not return values but function
should return value.

Thanks,
Vsandhyana

Is This Answer Correct ?    3 Yes 1 No

difference between stored procedure and function?..

Answer / arkchowdary

PL/SQL------------- It is a named PL/SQL Block.
------------- Which can take 1 or more values.
------------- It accepts Parameters.

Usage-------------- Reusability.
-------------- Precompatibility.


Whereas

Functions----------- It is a named PL/SQL Block.
----------- Which can take 1 or more values.
----------- It must a Returns value by using
return statement.

Is This Answer Correct ?    2 Yes 1 No

difference between stored procedure and function?..

Answer / ravi v

Function returns only 1 value, where as stored procedure
returns mutiple values.

Is This Answer Correct ?    1 Yes 2 No

Post New Answer

More Cognos Interview Questions

what is a query subjects item?

1 Answers   HCL,


How to write a condition for multy select in conditional formatting... Eg:- i added list,crosstab, barchart, columchart, guagechart, pie chart for value prompt by using static choices.. if i select multiple that all the things has to be display.. this is requirement how is possible to display..

2 Answers   IBM,


What do you do to make a report result in showing 4 different regions in an xl sheet in individual sheets(like Region1-sheet1,Region2-Sheet2 soon)?

5 Answers   IBM,


suppose i want to do drill through a column only for the values which is having more than > 50000. how can i do that?

2 Answers   Mind Tree,


1.How to apply sorting to Crosstab report? If so please give me example? 2.How to create Report level Joins?explain with example?

2 Answers   Cognizant,






If we are migrating lower version of Cognos reports (e.g. from Ver 7.0 to Cognos 8) then how we migrate Impromptu Catalog (ver 7.0) in Cognos 8? Do we create FM model for that? Please explain.

0 Answers   Wipro,


Can you define drill down and drill up?

0 Answers  


What are the types of studio?

0 Answers  


how to create relationship between emp and salgrade tables in frameworkmanager?

1 Answers   TCS,


How to do deployment?

5 Answers  


How do we drill through from a powerplay cube to reportnet?\

0 Answers   IBM,


What do you understand by the term ‘frame manager' in cognos and write all the layers of the framework manager model?

0 Answers  


Categories