Kodewick
Start learning →
Basic←→0 / 70

Long or short

#008BasicCASE4 min

The cinema wants a small tag on each movie in the schedule: 'long' if minutes is over 100, 'short' otherwise. Pick each movie's title and its tag.

The tables
movies
idtitlegenreminutesrating
1Robot Summerfamily958
2Dark Lakehorror1106
3Space Palsfamily887
4The Long Roaddrama1429
5Laugh Trackcomedy1015
6Snow Daycomedy927
6 rows
tickets
idmovie_iddayseatsprice
11Fri240
21Sat480
32Fri125
43Sat354
54Sun260
61Sun120
75Sat236
83Sun590
8 rows
query.sql
SELECT title,
  CASE
    -- your code here: WHEN minutes > 100 THEN 'long', and ELSE 'short' for the rest
  END
FROM movies;
Ctrl + Enter runs too
Result

Run shows what your query gives. When it looks right, Submit.