Cover Image

How to import & export sql file (MySQL Database) via Commandline

November 25, 2021 Reading time: ~1 minute
Import
mysql -u username -p database_name < file.sql

Export
mysqldump -u username -p database_name > file.sql

Hit Counter

25