15 July 2013

To import a MySQL database directly from the command line, you can use the mysql command with the appropriate options. The import process may take a few moments to complete, depending on the size of the database.

Source code viewer
  1. mysql -u root -p database_name < database.sql
Programming Language: Bash