diff --git a/database_cleanup/models/purge_tables.py b/database_cleanup/models/purge_tables.py index cde69fd8799..8d2dcf60919 100644 --- a/database_cleanup/models/purge_tables.py +++ b/database_cleanup/models/purge_tables.py @@ -72,7 +72,7 @@ def purge(self): ) self.logger.info("Dropping table %s", line.name) - self.env.cr.execute("DROP TABLE %s", (IdentifierAdapter(line.name),)) + self.env.cr.execute("DROP TABLE %s CASCADE", (IdentifierAdapter(line.name),)) line.write({"purged": True}) return True