CJCoding With Joseph
15free / daySign inCreate account

Olivia Gives Up Her Office

Olivia Grant (instructor id 10) is moving to remote teaching and no longer has an office. Set her office to NULL, the proper 'no value', not an empty string or the word 'none'. Only row 10 changes; Marcus Lindqvist (id 7) already has NULL there and stays as he is.

Expected result:

instructors after your statements: 12 rows
+----+------------+-----------+--------------------------------+---------------+------------+--------+--------+--------------+------------+---------------------+
| id | first_name | last_name | email                          | department_id | hire_date  | salary | office | phone        | is_tenured | title               |
+----+------------+-----------+--------------------------------+---------------+------------+--------+--------+--------------+------------+---------------------+
|  1 | Grace      | Okafor    | grace.okafor@school.example    |             1 | 2012-08-20 |  98500 | T-210  | 416-555-0201 |          1 | Professor           |
|  2 | Daniel     | Reyes     | daniel.reyes@school.example    |             1 | 2019-01-14 |  82000 | T-214  | 416-555-0202 |          0 | Assistant Professor |
|  3 | Mei        | Chen      | mei.chen@school.example        |             1 | 2016-09-01 |  88000 | T-218  | NULL         |          1 | Associate Professor |
|  4 | Samuel     | Whitaker  | samuel.whitaker@school.example |             2 | 2009-07-06 | 101000 | G-105  | 416-555-0204 |          1 | Professor           |
|  5 | Priya      | Natarajan | priya.natarajan@school.example |             2 | 2021-08-30 |  76500 | G-112  | 416-555-0205 |          0 | Lecturer            |
+----+------------+-----------+--------------------------------+---------------+------------+--------+--------+--------------+------------+---------------------+
(showing 5 of 12 rows)
Hints3 available
Topics:
INSERT, UPDATE & DELETE
1
Tab to indent (Esc then Tab to move on) · Ctrl+Enter to run · Ctrl+Space to expand shortcuts (sel, ins, desc)

Results

Run your SQL to see every statement's output here, then how it compares with the expected answer.

Not sure what is in a table? SHOW TABLES lists them and DESCRIBE students shows the columns — or open the database browser on the left.