1. UPDATE stmd SET student_no="10014D001"; 會將所有學號都改成 10014D001 2. UPDATE stmd SET student_name="張三豐" WHERE student_no="10014D001"; 會將學號 10014D001 的姓名欄更改 3. UPDATE stmd set depart_class="164D31",student_name="李四" WHERE student_no="10114D001";
另外 SQL中可加入運算
select depart_class,student_no,student_name,score1,score2,score3, (score1+score2+score3) as total_score, (score1+score2+score3)/3 as average_score from stmd group by student_no order by depart_class,student_no