migration problem
Hello everybody, this is my first time using drizzle and using an sql library for the first time. I was wondering why am I getting this error?
I deleted the migration folder (because i was looking up the discord to see if anyone has the same issue), generated it, and once I used the migrate command it it gave me this error
9 Replies
here is the migration file
Anyone?
Your db has already created those tables,
A simple solution if you are new to drizzle and sql is to drop the tables from the database and try to migrate again
That should work but what if I want to make changes just by simply adding another column into my table for example I added a presignedurl col
I don't think dropping the tables would be nice
i think they work on new migrations i dont i just get troubles
currently my project is dev only after it go in production i get fucked i think my migrations 😄
huh
hi
hey
Your migration script is trying to create the table, but it already exists. There are several reasons for why this might be the case, but bottom line your database is out of sync with your migration script.
Possible fixes are:
- Change the database to remove the inconsistencies (DROP TABLE)
- Change the migration scripts (e.g. CREATE [IF NOT EXISTS])
i followed but i keep getting this
heres my config file
Any1
Is there a reason why its giving me a bad request when i use the migrate command?