[MySql] 清空資料表 清空資料庫

清空資料表:
truncate table  tb_name;

清空資料庫:
查出資料庫所有table名稱

select table_name from information_schema.tables where TABLE_SCHEMA = 'databaseName'
可以用excel 或其他工具copy出來編輯
執行n行 truncate table  tb_name;

留言

這個網誌中的熱門文章

[Windows]密碼複雜性需求 停用密碼複雜度

net use 系統發生 1219 錯誤