UPDATE statement rows are used to modify the content. With this help, you can update the values of columns. The general syntax of this statement is given below.
mysql> UPDATE <table_name> SET column_name = value WHERE column_name = value;
With the UPDATE statement you use SET and WHERE clauses. Through WHERE clause, you have to tell which row to update the column. By SET clause, you target the particular column and update it. Let’s now try to understand it with an example.
mysql> update category set name = banana where name = apple;