SQL Errors on migrate a fresh install
See original GitHub issueIssue summary
SQL Error when trying to migrate
django.db.utils.OperationalError: near ")": syntax error
How to reproduce?
Freshly installed a wagtail project trying to isolate the issue. Followed the install instructions then tried to migrate
Technical details
- python3, django 3.0, wagtail 2.9
Issue Analytics
- State:
- Created 3 years ago
- Comments:6
Top Results From Across the Web
SQL Server 2012 setup and migration issues - Microsoft Learn
This article describes the SQL Server 2012 setup and migration issues.
Read more >Error after migrating the database from SQL Server 2005 to a ...
Problem; Solution. Problem. You have recently moved your database from SQL Server 2005 to a newer version, and now for some actions you...
Read more >Laravel migration "Connection refused" [2002] | Database ...
I installed fresh laravel and edited .env. Added my MAMP host:127.0.0.1, database:"abc", username:root, password:root and it then tried run ...
Read more >Transfer to new Server / Upgrade fails - sql error in migration ...
Once we've done all this, Omeka then tries to upgrade the installation, at which point it fails. On the new install we can...
Read more >Cannot connect to the SQL server after migration or new ...
After migrating the SQL server to a new machine, or deploying a new SQL server, you get the following error in the Configuration...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
There are a some things that I found, that could be useful:
python manage.py makemigrations
it generates something like this:The order here seems to be important, and it should be:
django.db.utils.IntegrityError: NOT NULL constraint failed: new__home_homepage.page_ptr_id
But after checking the migration guide, I saw that you need to add some manual queries, like:
django.db.utils.OperationalError: cannot start a transaction within a transaction
To fix this, I removed the
BEGIN;
and theCOMMIT;
lines in the querydjango.db.utils.OperationalError: near "DROP": syntax error
As per https://stackoverflow.com/a/1884893/4508187 it seems that sqlite doesn’t support
alter table drop constraint
It would be good to have some documentation about how to make this work on sqlite, or if not possible, to specify that sqlite can’t be used in the example provided
Hi,
I agree with @sarensabertooth, it would be good to have an easier way to implement wagtailtrans, or maybe more guidance on the documentation
I was trying to add this package to a fresh Wagtail installation, but I got that SQL error.
django.db.utils.OperationalError: near ")": syntax error
If this is something complex to add to a fresh Wagtail site, I can’t imagine how it would be to add it to a complex site.