How import dump database sql in current project?

14 views
Skip to first unread message

Dmitriy

unread,
Jul 10, 2015, 3:50:05 AM7/10/15
to rubyonra...@googlegroups.com
Hi

I have source code of project with migrations. i want run this project on my pc. I want create new mysql DB and import dates from dump file.

I cant undestand very good how correct import dump sql file in mysql database?

First  need i run migrations in project? And second import values from dump file? Please, help me.  Thank you.

Mike

unread,
Jul 10, 2015, 4:11:10 AM7/10/15
to rubyonra...@googlegroups.com
First run the migrations, so that Rails has the database in the situation that it thinks is right, then you can import the data (which I hope is in the same database format)

To import the data, you should be able to use something like

mysql -u username database < database_dump.sql

Dmitriy

unread,
Jul 10, 2015, 4:16:38 AM7/10/15
to rubyonra...@googlegroups.com
import command running i in mysql console or whe?

пятница, 10 июля 2015 г., 11:11:10 UTC+3 пользователь Mike написал:

Mike

unread,
Jul 10, 2015, 4:42:09 AM7/10/15
to rubyonra...@googlegroups.com
I just do it from the shell (command) prompt

Dmitriy

unread,
Jul 10, 2015, 8:56:43 AM7/10/15
to rubyonra...@googlegroups.com
thank you, Mike

пятница, 10 июля 2015 г., 11:42:09 UTC+3 пользователь Mike написал:
Reply all
Reply to author
Forward
0 new messages