ควิซ SQL: LIKE, IN & BETWEEN

This SQL quiz covers the handy WHERE operators LIKE, IN and BETWEEN. You will match text with % and _, check values against a list and filter ranges, including the edge cases that catch people out.

ง่าย 10 ข้อ ~5 นาที ผ่านที่ 80% SQLite

เลือกโหมด

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

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

ข้อ 1 จาก 10

What does this query return?

CREATE TABLE people (name TEXT, age INTEGER);
INSERT INTO people VALUES ('Anna', 22), ('Ben', 35), ('Bella', 28), ('Carl', 40), ('Dan', 30);
SELECT name FROM people WHERE name LIKE 'B%' ORDER BY name;
ดูเฉลย

A. Bella Ben % matches any number of characters (even zero), so 'B%' means "starts with B". ORDER BY name puts Bella before Ben.

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

  • Pattern matching with LIKE, % and _
  • Case sensitivity of LIKE in SQLite, MySQL and PostgreSQL
  • Checking a list of values with IN and NOT IN
  • BETWEEN includes both ends
  • Why the order of the BETWEEN bounds matters

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

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

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

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

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