PG::DuplicateTable: ERROR: relation “posts” already exists

后端 未结 6 942
温柔的废话
温柔的废话 2020-12-13 19:58

When I run rake db:migrate I get following output:

== 20141219011612 CreatePost: migrating ======================================= -- create_table("

6条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-13 20:49

    Check your db/schema.rb

    You most likely have the same table being created there in addition to a migration in db/migrate/[timestamp]your_migration

    You can delete the db/migrate/[timestamp]your_migration if it is a duplicate of the one found in the schema and it should work.

提交回复
热议问题