Write each query here, and run it on a real Postgres database in your browser.
Change and remove exactly the rows you mean, and read what Postgres reports back.
Scenario
Simplified's team records its videos again, renames them and cuts them. You write each change its server sends, so it hits only the rows you mean.
Simplified's videos table holds eight videos.
Can you change one row, and leave the other seven alone?
These queries change the table. After each run, you'll see videos as your query left it.
The team records The empty result again, and it comes out 15 seconds longer. Its id is 8.
Add 15 to that row's seconds, and to no other row's.
Queries and results, whose id is 3, gets one more example, so it runs 20 seconds longer.
An assistant wrote this UPDATE for it.
Predict its command tag, run it, then fix it.
The team cuts Generated ids, whose id is 5.
Before the DELETE, check its WHERE with a SELECT.
Send back every column of the rows that DELETE will remove.
Your SELECT sent back one row: Generated ids.
Now remove that row, with the same WHERE.
The team renames The primary key, whose id is 4, to Primary keys.
It also moves that row to chapter 1.
Change both cells with one UPDATE.
Say Simplified's server still finds that row by its old title, The primary key.
It adds 10 seconds to the row with that title.
Predict the command tag, then write that UPDATE and run it.
Not yet, and every row changed
The query has no WHERE, so every row passed.
End it with a WHERE that only one row passes, like WHERE id = 8.
syntax error at or near "WHERE"
Look just before WHERE.
A comma after the last value in SET is one too many.
column "Primary keys" does not exist
Text goes in single quotes, never double quotes: 'Primary keys'.
Each step passes once its query sends back the right rows, or makes the right change. Then mark the lab complete to unlock the next lesson.