[英]how to get number of last migration run in heroku?
我正在尝试在heroku上调试我的应用程序,似乎一次或多次迁移没有运行。 没有手动完成每次迁移,我试图弄清楚哪个迁移是最后一次迁移。
环境:rails,postgresql
从终端:
heroku pg:psql --app app_name db_name
select * from schema_migrations;
寻找最后一个条目
另一种方式......从终端
heroku run console --app app_name
class SchemaMigration<ActiveRecord::Base
end
然后写
SchemaMigration.last
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.