Question

I am trying to migrate from rails 2 to rails 3.

I am facing a strange problem.

The whole of application doesn't seem to pluralize the table names.

Mysql::Error: Table 'r_database.country_data' doesn't exist:

But my table has country_datas as the name.

App was working perfectly in rails 2.

Was it helpful?

Solution

rails 3 recognizes that (in english) data is already plural. you'll have to either add a custom inflection in initializers, or use set_table_name "country_datas" in your model.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top