I developped a simple rails application that runs perfectly on my development machine.
When I put it on the production server (Phusion Passenger/Nginx), it returns me that error in the my_app/log/production.log
file:
ActiveRecord::StatementInvalid (Could not find table 'categories')
What is wrong?
PS: After a naming error, the table name was edited manually but it works great in the development mode. I don't suspect that misnaming error.
Make sure you've run your database migrations on the production server
Manually editing tables is a huge no no in Rails. It'll give you more headaches than it is worth. If you need to change something, you're way better of generating a new migration to change it - even if it's just a name change. (You can however rollback the db changes, delete that last migration and create a new one - but like I said - it's more trouble than it's worth)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With