How can you change "Hansen" into "Nilsen" in the LastName column in the Persons table?
Explanation
UPFATE clause is used to modify values in database tables.
String literals should be enquoted.
UPDATE table_name SET column1 = value1, column2 = value2, ... WHERE condition;
Theory
  • The SQL UPDATE Statement

    The UPDATE statement is used to update existing records in a table.

    Syntax

    UPDATE table_name
    SET column1=value1,column2=value2,...
    WHERE some_column=some_value;
    

    Note

    Notice the WHERE clause in the SQL UPDATE statement! The WHERE clause specifies which record or records that should be updated. If you omit the WHERE clause, all records will be updated!
    Read more: The SQL UPDATE Statement

Следи за CodeGalaxy

Мобильное приложение Beta

Get it on Google Play
Обратная Связь
Продолжайте изучать
тесты по SQL
Cosmo
Зарегистрируйся сейчас
или Подпишись на будущие тесты