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
Can a table contain multiple primary key’s?
What is a file delimiter?
Is postgresql a server?
how to create a table index in mysql? : Sql dba
How many scalar data types are supported in pl/sql?
i have some prob lem to tell me about my self in interview first round ...
What is the difference between an inner join and an outer join?
Are stored procedures compiled?
Mention what does the hierarchical profiler does?
what are date and time functions in mysql? : Sql dba
Why are indexes and views important to an organization?
What is compilation error in pl sql?
How do you write an inner join query?
How do I partition in sql?
Why cross join is used?