Question

I have a rails app in which there is a lot of data in the database. I have come to realise that on heroku only PostgreSQL is supported. Now my database is MySQL. Is there any way I can get rails to copy all the data from the database into the seed file without me having to type everything out by hand?

Était-ce utile?

La solution

No rails does not have the ability to do that.

You can look into the mysqltopostgres gem. This blog entry covers the usage pretty well. http://onestoryeveryday.com/mysql-to-postgresql-conversionmigration.html

Autres conseils

Heroku supports MySQL with the ClearDB addon.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top