Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Lära Challenge: Mark Archived Books As Unavailable | Updating & Deleting Data
Introduction to SQL
course content

Kursinnehåll

Introduction to SQL

Introduction to SQL

1. Getting Started
3. Sorting Data
4. Populating a Database
5. Updating & Deleting Data

book
Challenge: Mark Archived Books As Unavailable

As you were going through the book records, you noticed that several older books are still marked as available, even though they are reserved for archival purposes. You need to update the is_available column to FALSE for all books that are:

  • Published before the year 1950;
  • Belong to the Historical Fiction or Classic genres.
Uppgift

Swipe to start coding

Your task is to write an UPDATE statement to modify multiple rows in the books table based on these conditions.

Note

The rows that are to be modified must match both of the conditions.

Lösning

Switch to desktopByt till skrivbordet för praktisk övningFortsätt där du är med ett av alternativen nedan
Var allt tydligt?

Hur kan vi förbättra det?

Tack för dina kommentarer!

Avsnitt 5. Kapitel 4
toggle bottom row

book
Challenge: Mark Archived Books As Unavailable

As you were going through the book records, you noticed that several older books are still marked as available, even though they are reserved for archival purposes. You need to update the is_available column to FALSE for all books that are:

  • Published before the year 1950;
  • Belong to the Historical Fiction or Classic genres.
Uppgift

Swipe to start coding

Your task is to write an UPDATE statement to modify multiple rows in the books table based on these conditions.

Note

The rows that are to be modified must match both of the conditions.

Lösning

Switch to desktopByt till skrivbordet för praktisk övningFortsätt där du är med ett av alternativen nedan
Var allt tydligt?

Hur kan vi förbättra det?

Tack för dina kommentarer!

Avsnitt 5. Kapitel 4
Switch to desktopByt till skrivbordet för praktisk övningFortsätt där du är med ett av alternativen nedan
Vi beklagar att något gick fel. Vad hände?
some-alt