delete 語句用於刪除表中的數據, 基本用法為:
delete from 表名稱 where 刪除條件;
以下是在表 students 中的實例:
刪除 id 為 3 的行: delete from students where id=3;
刪除所有年齡小於 21 歲的數據: delete from students where age<20;
刪除表中的所有數據: delete from students;
delete 語句用於刪除表中的數據, 基本用法為:
delete from 表名稱 where 刪除條件;
以下是在表 students 中的實例:
刪除 id 為 3 的行: delete from students where id=3;
刪除所有年齡小於 21 歲的數據: delete from students where age<20;
刪除表中的所有數據: delete from students;
本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。