当我尝试在 Heroku 上迁移我的数据库时出现迁移错误。在此处找到提供此建议的解决方案:
rake db:create
rake db:schema:load
rake db:migrate
但这并没有什么不同。错误是这样开始的:
PG::UndefinedColumn: ERROR: column "property_id" of relation "bookings" does not exist
我不再有 property_id 列,因为这在以后的本地迁移中发生了变化。顺便说一句,我的迁移在本地工作,为什么不在 Heroku 上呢?