0

有人知道如何导出数据库吗?

我正在使用 TeraTerm,我想导出数据库以进行备份。我尝试在谷歌上搜索该命令,但找不到。

编辑:

感谢您花时间和精力回答我的问题。数据库已经导出。我用这个:

    mysqldump -u root -ptest test_db > backup.sql
4

2 回答 2

1

You can use the mysqldump command this way:

mysqldump -u root -ptest test_db > backup.sql

Where username is root, root password is test and database name is test_db

于 2015-05-26T07:29:33.973 回答
0

If you are using mysql database, then there are numerous ways you can do that. One is that you can set up 'phpmyadmin' on your server and export the database using the phpmyadmin web interface. Or you can use this command: "mysqldump -u [user] -p[password] [database-name]" > [database-export-file-name.sql]

Note that there is no space between -p and password.

See this for reference: http://www.itworld.com/article/2833078/it-management/3-ways-to-import-and-export-a-mysql-database.html

于 2015-05-26T07:28:34.370 回答