Last active
May 19, 2020 05:24
-
-
Save aayushdrolia/56d8b1cfc1deabf9f479e01111b56b0a to your computer and use it in GitHub Desktop.
Import & Export Database using Command Line Interface
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Import Command | |
-------------- | |
mysql -u [username] -p -e "create database [databasename];" | |
mysql -u[username] -p [databasename] < [.sql filename] | |
Export Command | |
-------------- | |
mysqldump -u [username] -p [databasename] > [output path] | |
example: mysqldump -u root -p db-one > /Downloads/Databases/db-one.sql |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thank you sharing the information.