新手问题 遇到一个错误 ActiveRecord::StatementInvalid (Could not find table 'users') 求解

chrisyu · September 08, 2017 · Last by chrisyu replied at September 11, 2017 · 2025 hits

学习 rails,注册一个用户,点注册按钮遇到报错,求大神告知怎么办

rake db:migrate我猜是这个没执行?

Reply to hging

你好 已经执行啦这个命令 这就是数据库迁移吧

确定你的 model 有 user,数据库里有这个表吗

肯定有的

rails db:create db:migrate RAILS_ENV=production 你的 log 是 production 然而 production.sqlite3 文件是空的

Reply to zaqmjuop

谢谢帮助。。就是这个问题环境没搞清楚

You need to Sign in before reply, if you don't have an account, please Sign up first.