SQL-Quiz: SELECT & WHERE

This SQL quiz checks the two clauses every query starts with, SELECT and WHERE. You will predict query results, combine conditions with AND and OR, and spot why a query fails.

Leicht 10 Fragen ~5 Minuten Bestanden ab 80% SQLite

Modus wählen

Du spielst als Gast: Melde dich an, damit XP und Serie gespeichert werden.

Beispielfrage

Frage 1 von 10

What does this query return?

CREATE TABLE users (id INTEGER, name TEXT, age INTEGER, city TEXT);
INSERT INTO users VALUES (1, 'Ana', 31, 'Paris'), (2, 'Ben', 25, 'Rome'), (3, 'Cy', 40, 'Paris');
SELECT name FROM users WHERE id = 2;
Lösung zeigen

A. Ben WHERE id = 2 keeps only Ben's row, and SELECT name returns just the name column. The id is used for filtering but not returned.

Darum geht es in diesem Quiz

  • Choosing columns with SELECT and SELECT *
  • Filtering rows with WHERE and comparison operators
  • Combining conditions with AND, OR and parentheses
  • Quoting text values with single quotes
  • Why a column alias cannot be used in WHERE

Häufige Fragen

Brauche ich ein Konto?

Nein. Jeder kann spielen. Mit Anmeldung werden XP, Serie, Abzeichen und Verlauf gespeichert.

Kann ich es wiederholen?

Ja. Dein Bestwert bleibt erhalten, und Fragen und Antworten werden jedes Mal neu gemischt.