import

By big imports I mean creating millions of nodes and indexing them fo apache solr search. We needed to import 1 million records from file and we needed to create 3 nodes for each record, one in each of our 3 languages. So this gave us the task of creating scripts for creating, updating and deleting 3 millions nodes.

Goto the location on your server where your file is using cd command

cd /var/www 

To see your location in the server directory tree use pwd command
pwd

For a list of all your databases:
$ mysql -u root -h localhost -p -Bse 'show databases'

To dump your database:

$ mysqldump -u root -h localhost -pmypassword faqs | database_name -9 > database_name.sql

To import your database:

mysql -u user -ppassword --default-character-set=utf8 database < "database_name.sql"

Syndicate content