How to Update Rows in Oracle SQL
Update Command
Update Command is used to update existing records or rows of a database table. Update Command is applied when some changes happens in records. Suppose in case of an employee if he changes his city ,then his record in database must be updated. Another example could be for annual increments in salaries of all the employees, we need update command.
The general syntax of Update Command is give below
Update table name set column name=new value;
Example
Suppose you want to change present city of employee named Adam to Chandigarh
Update employee set ecity=’Chandigarh’ where ename=’Adam’;
You can also use arithmetic operators in update, like increment the salary of all the employees by 100.
The update statement will be like this: