且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

在DELETE CASCADE上删除

更新时间:2023-02-02 22:54:56

  • 将数据库导出为 .sql 文件
  • 然后按 ctrl + H 将所有 ON DELETE CASCADE 替换为".
  • 然后从数据库中删除表,并使用新文件实例化一个新文件,而无需 ON DELETE CASCADE
    • Export the database as a .sql file
    • Then press ctrl + H to replace all ON DELETE CASCADE with ""
    • Then drop the tables from the DB and use the new file to instantiate a new one without ON DELETE CASCADE