CoursePlanner | Knowledge Graph Project | Graph Database library
kandi X-RAY | CoursePlanner Summary
kandi X-RAY | CoursePlanner Summary
Knowledge Graph Project
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of CoursePlanner
CoursePlanner Key Features
CoursePlanner Examples and Code Snippets
Community Discussions
Trending Discussions on CoursePlanner
QUESTION
Throughout writting my app many times I have had to delete my database and re run my migrations. This has always worked by simply deleteing the database file then just running manage.py migrate
. However now when I try to do this, I get an error saying django.db.utils.OperationalError: no such table: Planner_course
where Planner is my app name and Course is one of my class schemas. What I am doing essentially follows this answer.I am unsure why less than a week ago I was able to reset my database using this method and now I cannot. Does anybody have any ideas? I get error wether I run makemigrations
migrate
or even runserver
, where as everyother time it would simply remake the db and apply the migrations when I reran the migrations with no db. Here is the full error code:
ANSWER
Answered 2020-Mar-10 at 21:28I ended up solving this by wiping all imports of views.py as well, for some reason that worked. My advice to anyone else in this situation:
- create a backup of your project folder
- delete db from project folder
- clear all imports of views.py. For example this might be imported in your urls.py and in models.py.
Then, run
migrations
if you kept your migrations ormakemigrations
if you didntThis should rebuild your db. Copy this new db to a folder somewhere you will remember
Restore all files from your backup
copy new db into restored project(replace old db)
cheers
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install CoursePlanner
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page