You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to downgrade the database, I get the following error:
"Cannot drop index 'ix_post_user_id': needed in a foreign key constraint"
I assume that I need to change something in one of the migrations files to solve this problem. I am running a local MySQL server so it might be related to that
The text was updated successfully, but these errors were encountered:
DRuyters
changed the title
Chapter 4: Problem with slask db downgrade
Chapter 4: Problem with 'flask db downgrade base'
Aug 31, 2024
If this happens with the "posts table" migration included in this project, then my guess is that there is some small difference between sqlite (which is what I used when the migrations were generated) and MySQL. You can try moving the drop table call to the top to see if that helps.
Hello,
When trying to downgrade the database, I get the following error:
"Cannot drop index 'ix_post_user_id': needed in a foreign key constraint"
I assume that I need to change something in one of the migrations files to solve this problem. I am running a local MySQL server so it might be related to that
The text was updated successfully, but these errors were encountered: