What is difference between a Cursor declared in a procedure
and Cursor declared in a package specification ?
Answer Posted / ratan singh sengar
SP is a set of SQL Statements that resides in server. Advantage of SP is just that it is pre compiled and available in the server. So, whenever this SP is called, its executed instantly since its already been compiled. This makes the faster performance while executing the SP.
cursor:
Cursors are add on feature of SP , for row by row validations.
For instance : You have a list of employees belong to various department. For calculating the bonus % which varies for department to department, you use cursors to calculate Bonus.
| Is This Answer Correct ? | 0 Yes | 4 No |
Post New Answer View All Answers
What is a recursive stored procedure?
Why do you partition data?
What is delimiter sql?
how to use 'mysql' to run sql statements? : Sql dba
Can we create a trigger on view?
How to use boolean type in select statement?
in oracle 10g sw after compiling procedure how to pass parameter values ,if we (v_empid out number)how to give empid after successful compilation program.This site exact suitable for 10g with respect to question & answer same format , im trying sql browser & sql command prompt using exec procedure name & respective parameters.
what is the difference between sql and t-sql? : Transact sql
What do you mean by query optimization?
What is Difference Between Unique and Primary Key Constraints?
What is the process of debugging?
what are the different type of normalization? : Sql dba
What does trigger mean in slang?
what is query cache in mysql? : Sql dba
What are the different type of joins in sql?