#30579 closed New feature (wontfix)
Add management command to delete all tables.
Reported by: | Victor Porton | Owned by: | nobody |
---|---|---|---|
Component: | Migrations | Version: | dev |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
Please add management command to delete all tables from the DB.
Currently I need to drop the DB, create it again, and then configure (e.g. create PostgreSQL extensions) it again. That's very inconvenient.
Change History (5)
comment:1 by , 6 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Summary: | Add management command to delete all tables → Add management command to delete all tables. |
Version: | 2.2 → master |
comment:2 by , 6 years ago
I know about flush command. It does not delete the tables themselves, as I need!
comment:3 by , 6 years ago
Resolution: | invalid → wontfix |
---|
I'm sorry but I don't think that your use case is so common that we should add a new management command to the Django. You can try to use connection.introspection.table_names()
and prepare your own custom command.
comment:4 by , 6 years ago
I'm sorry but I don't think that your use case is so common that we should add a new management command to the Django.
It is very useful when some serious migration error happens during development.
Please add this functionality.
comment:5 by , 6 years ago
I wouldn't say that it is common. I cannot remember when I recreated database from scratch due to a "serious migration error". You can add this custom command in your own project. Please use one of support channels if you need any help with that.
Follow triaging guidelines with regards to wontfix tickets.
If you want to flush all data from tables you can use django-admin flush.