# UPDATE Statement

__*UPDATE syntax*__

+ syntax:
```12
UPDATE table_name ~!@SET col_name1=expression1@!~
  [,col_name2=expression2,...]
  [WHERE condition]
  [ORDER BY ...]
  [LIMIT row_count];

tidb> SELECT count(*) FROM universe.planets;
+----------+
| count(*) |
+----------+
|       10 |
+----------+

tidb> UPDATE universe.planets SET gravity = 0.0;
Query OK, 10 rows affected (0.01 sec)
Rows matched: 10  Changed: 10  Warnings: 0
```
------------------------------------------------------------
Other than the assignment clause, the syntax for other UPDATE clauses are very similar to SELECT, essentially finding existing table rows and then modify them. If you are unfamiliar with SELECT statement, please return to the preamble course 201.2 Learn SQL from TiDB first.