Multiple choice technology databases

Instead of Cursor what can be used to perform row by row operation there by increasing performance?

  1. Corelated Subquery

  2. Index

  3. TOP()

  4. None

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

Correlated subqueries can often replace row-by-row cursor operations and significantly improve performance. Cursors are slow because they process one row at a time with frequent context switching. A correlated subquery executes set-based operations which are optimized by the query engine. Indexes (option B) improve data access but don't replace row-by-row logic. TOP() (option C) returns a specified number of rows but doesn't perform row-by-row operations.