Run .sql file through command line in MySQL



I have a file to create tables in the mysql DB on the cloud server, the file is in the same folder which I uploaded to set up my workspace, how do I run the sql script file from the command line of the cloud 9 workspace IDE?


I believe the line goes:

mysql -u username -p database_name < file.sql

That should import the file to the database.

Hope this helps.

How do I pull a new version of my joomla website from bitbucket?