Solution Link
Solution
How to delete a single table in Django 4.0:
- Remove <YourDeleteTable> model from
models.py
file - Remove <YourDeleteTable> class from
admin.py
file and ALL other instances of wherever this class is used. python manage.py makemigrations <<your app>>
python manage.py migrate
Background
I wrote this guide because I lost all my data from following a different guide on Stack Overflow. T_T
Top comments (2)
Hi there, we encourage authors to share their entire posts here on DEV, rather than mostly pointing to an external link. Doing so helps ensure that readers donβt have to jump around to too many different pages, and it helps focus the conversation right here in the comments section.
If you choose to do so, you also have the option to add a canonical URL directly to your post.
Will do