Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Вивчайте Challenge: Blockbuster Filter | Conditional Filtering and Sorting with CASE WHEN
Mastering CASE WHEN in SQL
Секція 3. Розділ 3
single

single

Challenge: Blockbuster Filter

Свайпніть щоб показати меню

Завдання

Проведіть, щоб почати кодувати

Write a query that selects the title, genre, rating, and box_office columns from the movies table. Use a CASE WHEN expression to add a column that labels each movie as 'Blockbuster' if its box_office is greater than or equal to 100,000,000 or its rating is greater than or equal to 8.5. Otherwise, label it as 'Standard'.

  • Select the columns title, genre, rating, and box_office from the movies table.
  • Add a column using a CASE WHEN expression to label each movie as 'Blockbuster' or 'Standard' based on the criteria above.
  • Name the new column blockbuster_status.

Рішення

Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Все було зрозуміло?

Як ми можемо покращити це?

Дякуємо за ваш відгук!

Секція 3. Розділ 3
single

single

Запитати АІ

expand

Запитати АІ

ChatGPT

Запитайте про що завгодно або спробуйте одне із запропонованих запитань, щоб почати наш чат

some-alt