Mysql的:沿着数据转储数据库 [英] Mysql : dump database along data

查看:79
本文介绍了Mysql的:沿着数据转储数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我也想使用unix命令行沿表模式和表数据转储数据库.

I want to dump my database along the table schema and the table data also using the unix command line .

我用过.

mysqldump -d -u root  -p frontend > frontend.sql

但是上面的命令仅转储模式,而不转储数据库中的数据.

But above command is dumping only schema not the data from the database .

请帮助我如何将数据库也随数据一起转储.

Please help me out how can i dump the database along the data also.

推荐答案

backup: # mysqldump -u root -p[root_password] [database_name] > dumpfilename.sql

可以,

如果您的要求是仅转储数据,则可以这样做

If your requirement is to dump data alone then go for this,

要导出到文件(仅数据)

To export to file (data only)

mysqldump -u [user] -p[pass] --no-create-db --no-create-info mydb > mydb.sql

这篇关于Mysql的:沿着数据转储数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆