Meet the table · SELECT, FROM, ORDER BY id and LIMIT as a preview · level 3 of 6
Six rows, six characters?
Level 3: Predict the result · Exercise 1 of 2
A teammate runs SELECT characterName FROM scripts ORDER BY id LIMIT 6, sees six rows, and announces six different characters. Those six rows are ids 1 to 6, the opening of the Pilot. The query below lists each different name among those six rows once. Before you run it, how many rows does it return?
SELECT DISTINCT characterName
FROM scripts
WHERE id <= 6
ORDER BY characterName;
The query. Predict before you run it.
Data: Rick & Morty.
Opens once your prediction is right, or after the worked answer.
Query results
The real result appears here after you run it.
The real result appears here after you run it.
Practice here is evidence for you and your instructor, never a grade. Grades live in Canvas.