Bird
0
0

Given the EXPLAIN output:

medium📝 query result Q4 of 15
PostgreSQL - Performance Tuning
Given the EXPLAIN output:
Seq Scan on products  (cost=0.00..100.00 rows=10 width=50)

What does the rows=10 indicate?
AMaximum rows allowed in the table
BEstimated number of rows the query will return
CNumber of rows scanned so far
DNumber of rows currently in the table
Step-by-Step Solution
Solution:
  1. Step 1: Understand the meaning of rows in EXPLAIN

    Rows shows the planner's estimate of rows output by this step.
  2. Step 2: Differentiate from actual row counts

    It is an estimate, not actual scanned or total rows in table.
  3. Final Answer:

    Estimated number of rows the query will return -> Option B
  4. Quick Check:

    rows=10 means estimated output rows [OK]
Quick Trick: rows= shows estimated output rows, not actual count [OK]
Common Mistakes:
  • Thinking rows= is actual scanned rows
  • Confusing rows= with total table rows
  • Assuming rows= is a limit

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More PostgreSQL Quizzes