Bird
0
0

If effective_cache_size is set too low, what is the likely effect on query planning?

medium📝 query result Q5 of 15
PostgreSQL - Performance Tuning
If effective_cache_size is set too low, what is the likely effect on query planning?
AThe planner will overestimate memory and cause out-of-memory errors
BThe planner may underestimate available cache and choose less efficient query plans
CThe database will allocate more memory than available causing slowdowns
DNo effect on query planning, only affects disk caching
Step-by-Step Solution
Solution:
  1. Step 1: Understand planner's use of effective_cache_size

    The planner uses this to estimate how much data might be cached in memory.
  2. Step 2: Effect of setting it too low

    If too low, planner assumes less cache, may avoid index scans or joins, picking slower plans.
  3. Final Answer:

    The planner may underestimate available cache and choose less efficient query plans -> Option B
  4. Quick Check:

    Low effective_cache_size = conservative planner estimates [OK]
Quick Trick: Low effective_cache_size makes planner cautious, picks slower plans [OK]
Common Mistakes:
  • Thinking it causes memory errors
  • Assuming it affects actual memory allocation
  • Believing it has no effect on planning

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More PostgreSQL Quizzes