SQL Server Update

SQL Server Update command is to modify the data in table.


UPDATE table_name
set column=value
where condition

Examples are based on following table

Increment the employees salaries to 18% for department number 20.
Update emp
set salary=salary*1.18
where deptno=20

Change the David location from London to Sydney
Update emp
set location=‘Sydney’
where empname=‘David’

Powered by k2schools