Support the ongoing development of Laravel.io →
posted 6 years ago
Database
Last updated 4 months ago.
0

usually it means that when migrations happened, it didnt create the table as there was an error so the alter statement is failing

there could also be the case that one of the migrations might have a different table for down() section so when you rollback you accidentally delete the other table so when down() method for the actual table happens it gives an error (i have done this especially when i copy/paste a migration to create new ones)

now you can confirm this by logging in to SQL and checking whether that table exists or not..

if it does.. try running that SQL (alter statement) manually

0

shez1983 said:

usually it means that when migrations happened, it didnt create the table as there was an error so the alter statement is failing

there could also be the case that one of the migrations might have a different table for down() section so when you rollback you accidentally delete the other table so when down() method for the actual table happens it gives an error (i have done this especially when i copy/paste a migration to create new ones)

now you can confirm this by logging in to SQL and checking whether that table exists or not..

if it does.. try running that SQL (alter statement) manually

Sorry but I do not get it Im not good with SQL and Databases, I did made a new DB but that didn'tm work. What can I try to solve this?

0

Schema::table is to modify an existing table, use Schema::create to create new. ;)

1

astroanu said:

Schema::table is to modify an existing table, use Schema::create to create new. ;)

Dayum thats right, missed it completly!

0

astroanu. Thanks :-)

0

astroanu said:

Schema::table is to modify an existing table, use Schema::create to create new. ;) ....

woou its work thanks alot

1

Schema::table is to modify an existing table, use Schema::create to create new. ;)

0

Sign in to participate in this thread!

Cloudways

Your banner here too?

xJoeyv xjoeyv Joined 17 Sep 2016

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

The Laravel portal for problem solving, knowledge sharing and community building.

© 2022 Laravel.io - All rights reserved.