Larry Kelly
2006-Jun-28 17:23 UTC
[Rails] Is there a rake task to extract data from a database/table
I know I can get the schema by running
rake db_schema_dump
but, is there a way to ge the data from a table or a database into a format
that can be quickly converted to a migration. What I''m really trying
to do
is synch my local development database (schema and data) with the db on my
hosting service.
--
Best Regards,
-Larry
"Work, work, work...there is no satisfactory alternative."
--- E.Taft Benson
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://wrath.rubyonrails.org/pipermail/rails/attachments/20060628/a40169bf/attachment.html
Michael Greenly
2006-Jun-28 19:13 UTC
[Rails] Re: Is there a rake task to extract data from a database/tab
Larry Kelly wrote:> I know I can get the schema by running > > rake db_schema_dump > > but, is there a way to ge the data from a table or a database into a > format > that can be quickly converted to a migration. What I''m really trying to > do > is synch my local development database (schema and data) with the db on > my > hosting service.I''d recomend running the same database on your development machine as that on your production server and use the native datbase dump/restore methods. You can then wrap them with rake commands if you want. Examples of what you need to do can bee seen in the code for the default rake tasks that synch test to development. -- Posted via http://www.ruby-forum.com/.