MySQL: import a dump

Martin ZellerMySQL Leave a Comment

If you have got a sql-File and want to import it to your MySQL database then you can do this with a simple line in the shell: [shell] mysql -u username -p password -h databaseservername  datebasename < sqlfile.sql [/shell] Example: Say there is a local MySQL database, with a database called ‘mybestsellers’, we have got a dump file ‘/home/users/jripper/bestsellerdump.sql’ and …