ควิซ SQL: Query Performance

This SQL quiz covers the performance questions that come up in backend interviews. You will read query plans, fix N+1 queries and slow pagination, and spot conditions that stop an index from being used.

ปานกลาง 10 ข้อ ~6 นาที ผ่านที่ 80% SQLite

เลือกโหมด

กำลังเล่นแบบผู้เยี่ยมชม: เข้าสู่ระบบเพื่อเก็บ XP และ streak

ตัวอย่างคำถาม

ข้อ 1 จาก 10

What does EXPLAIN (or EXPLAIN QUERY PLAN in SQLite) show you?

ดูเฉลย

A. How the database plans to run the query: which indexes, scans and join order it uses The plan tells you whether a table is scanned in full or searched through an index, and in what order joins happen. In PostgreSQL EXPLAIN ANALYZE also runs the query and shows real timings, so be careful with it on UPDATE or DELETE.

ควิซนี้มีเนื้อหาอะไรบ้าง

  • Reading plans with EXPLAIN
  • N+1 queries and SELECT *
  • Keyset pagination instead of large OFFSET
  • Index-friendly conditions and type mismatches
  • Batching writes and keeping statistics fresh

คำถามที่พบบ่อย

ต้องมีบัญชีไหม?

ไม่ต้อง ใครก็เล่นได้ เข้าสู่ระบบเพื่อเก็บ XP, streak, เหรียญตรา และประวัติ

ทำซ้ำได้ไหม?

ได้ ระบบเก็บคะแนนที่ดีที่สุดไว้ และสลับคำถามกับตัวเลือกใหม่ทุกครั้ง