What are the disadvantages of cursors? How can you avoid
cursors?

Answers were Sorted based on User's Feedback



What are the disadvantages of cursors? How can you avoid cursors?..

Answer / rahul kumar

A) In cursors each time you fetch a new row it does a round
trip with the database thereby increase network use and time.

B) There is also restriction on select statements that can be
used in cursors

C) It also uses more resources and temporary memory

Cursors can be avoided with the help of careful
implementation of while loop and other set based operations

Is This Answer Correct ?    13 Yes 2 No

What are the disadvantages of cursors? How can you avoid cursors?..

Answer / gogune s k

Overload for RAM to process each row and time consuming.
Bulk collect can be used in place of cursors in some cases.

Is This Answer Correct ?    3 Yes 1 No

Post New Answer

More DB Development Interview Questions

What is the physical representation for a many-to-many relationship?

0 Answers  


Does QTP Support the Propjects which are running in Dot Net? As we are starting with new project in Dot net need to use automation tool?Please advice & let me know what would be the best.

0 Answers  


Explain about a primary key?

0 Answers  


Given an employee table, how would you find out the second highest salary?

9 Answers  


Explain about normal forms?

0 Answers  






What is an application role and explain a scenario when you would use one?

0 Answers  


Explain the rollup operator?

0 Answers  


What is a join and explain different types of joins?

2 Answers  


How can you log an error to the server event log from a stored procedure?

0 Answers  


Write short notes on manual refreshes.

0 Answers  


What is the maximum length of an extended property?

0 Answers  


Which four data types cannot be used as a return type from a user-defined function?

0 Answers  


Categories