1. 修改单个列的值:
```sql
UPDATE 表名 SET 列名=新值 WHERE 条件;
```
示例:
```sql
UPDATE student SET name='张三' WHERE id=1;
```
2. 修改多个列的值:
```sql
UPDATE 表名 SET 列名1=新值1, 列名2=新值2, ... WHERE 条件;
```
示例:
```sql
UPDATE student SET name='张三', age=20 WHERE id=1;
```
3. 修改所有行的值:
```sql
UPDATE 表名 SET 列名=新值;
```
示例:
```sql
UPDATE student SET age=20;
```
4. 使用子查询来更新数据:
```sql
UPDATE 表名 SET 列名=子查询 WHERE 条件;
```
示例:
```sql
UPDATE student SET age=(SELECT AVG(age) FROM student) WHERE id=1;
```
5. 使用JOIN来更新数据:
```sql
UPDATE 表1 JOIN 表2 ON 条件 SET 表1.列名=新值;
```
示例:
```sql
UPDATE student JOIN score ON student.id=score.student_id SET student.age=20 WHERE score.score>80;
```