-
-
Notifications
You must be signed in to change notification settings - Fork 220
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error in db restore: no such table #257
Comments
Hello @rgaiacs |
Be backup starts with
and later it has
|
@rgaiacs Hmmm, |
the --clean option for postgresql needs to add --if-exists this is what causes this error https://github.com/django-dbbackup/django-dbbackup/blob/master/dbbackup/db/postgresql.py#L51 but it honestly is a good thing and you should simply add --if-exists when adding --clean link to pg_dump docs: https://www.postgresql.org/docs/10/app-pgdump.html |
I've been receiving the same warnings: 'UserWarning: Error in db restore: no such table: main.auth_permission and some anothers: 'UserWarning: Error in db restore: FOREIGN KEY constraint failed 'UserWarning: Error in db restore: index django_content_type_app_label_model_76bd3d3b_uniq already exists Any suggestions? ( I'm using SQLite3) |
Is your problem resolved since then? I have almost the same problem with SQLite3 as well and could not find any useful issue pointing out this particular problem. If I run the |
Having the same issue, where the tables are created in alphabetical order and this creates conflicts:
The the models above, result in this in the dump:
Which then results in UserWarning: Error in db restore: no such table: main.expenses_expensetype |
When I try to restore the database I receive
The text was updated successfully, but these errors were encountered: