Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close
Introduction
UNIQUE
NOT NULL
CHECK
20. CHECK - updating rows
DEFAULT
Summary

Instruction

Superb! As you can see, all the values were in accordance with our CHECK constraints, so we inserted the row successfully. But what if we change it?

Exercise

Try to update a row in the table video_game. Pick the row with the name 'Grand Theft Auto V' and change the price to -2. What do you think will happen?

Stuck? Here's a hint!

Type

UPDATE video_game 
SET price = -2 WHERE name = 'Grand Theft Auto V';