SQL UPDATE Query

The SQL UPDATE Query is used to modify the existing records in a table. You can use the WHERE clause with the UPDATE query to update the selected rows, otherwise all the rows would be affected.

Syntax
The basic syntax of the UPDATE query with a WHERE clause is as follows −

UPDATE table_name SET column1 = value1, column2 = value2...., columnN = valueN WHERE [condition];

You can combine N number of conditions using the AND or the OR operators.

Scroll to Top