|
LastName |
FirstName |
Address |
City |
ABC |
EFG |
1, |
|
XYZ |
|
3, Second St |
|
LastName |
FirstName |
Address |
City |
ABC |
EFG |
1, |
|
XYZ |
EFG |
3, |
|
UPDATE |
The UPDATE statement is used to modify data in a table. The syntax of the UPDATE statement is: UPDATE <table name> SET <column name=new value> WHERE <condition> The WHERE clause is optional just like in the SELECT statement, while the SET clause updates(assigns new value to) selected rows in the table. Consider the following example: Student |
We want to add a FirstName to the student with the LastName XYZ. UPDATE Student SET FirstName='EFG' WHERE LastName='XYZ' |