Sunday, 15 January 2012

ruby on rails - ActiveRecord::StatementInvalid (Could not find table) -



ruby on rails - ActiveRecord::StatementInvalid (Could not find table) -

i've got rails application on digitalocean. i'm using comfortable mexican sofa cms. added gem , ran rails generate comfy:cms , rake db:migrate when navigate example.com/admin, 500 error , application isn't able find necessary tables. here's error in logs.

i, [2014-06-24t21:51:18.397255 #18789] info -- : started "/" 173.10.20.190 @ 2014-06-24 21:51:18 +0000 i, [2014-06-24t21:51:18.425183 #18789] info -- : processing homecontroller#index html i, [2014-06-24t21:51:18.442366 #18789] info -- : rendered home/index.html.erb within layouts/application (1.2ms) i, [2014-06-24t21:51:18.445116 #18789] info -- : completed 200 ok in 20ms (views: 9.5ms | activerecord: 0.0ms) i, [2014-06-24t21:51:18.599085 #18786] info -- : started "/assets/rails.png" 173.10.20.190 @ 2014-06-24 21:51:18 +0000 i, [2014-06-24t21:51:23.516755 #18789] info -- : started "/admin" 173.10.20.190 @ 2014-06-24 21:51:23 +0000 i, [2014-06-24t21:51:23.522184 #18789] info -- : processing comfy::admin::cms::basecontroller#jump html i, [2014-06-24t21:51:23.526053 #18789] info -- : completed 500 internal server error in 4ms f, [2014-06-24t21:51:23.532357 #18789] fatal -- : activerecord::statementinvalid (could not find table 'comfy_cms_sites'):

what seems unusual me when run rails c , activerecord::base.connection.tables, tables show , 'comfy_cms_sites' there.

make sure you've run migrations on production db with

rake db:migrate rails_env=production

ruby-on-rails activerecord sqlite3

No comments:

Post a Comment