The data stored in a table can be updated using the
UPDATE people SET age=2 WHERE name='Roger'
It’s important to add the
WHERE clause, otherwise this instruction:
UPDATE people SET age=2
would update all rows in the table.
More database tutorials:
- SQL, Unique and Primary keys
- SQL, how to update data
- Information systems, data and information
- The MongoDB basics tutorial
- PostgreSQL User Permissions
- Introduction to SQL
- SQL, how to delete data and tables
- How to list all users in PostgreSQL
- What is a Database? And a DBMS?