mysqldump 参数说明

旅行者

FormatDescriptionIntroduced
--add-drop-database</td>Add DROP DATABASE statement before each CREATE DATABASE statement</td> </td>
--add-drop-table</td>Add DROP TABLE statement before each CREATE TABLE statement</td> </td>
--add-drop-trigger</td>Add DROP TRIGGER statement before each CREATE TRIGGER statement</td> </td>
--add-locks</td>Surround each table dump with LOCK TABLES and UNLOCK TABLES statements</td> </td>
--all-databases</td>Dump all tables in all databases</td> </td>
--allow-keywords</td>Allow creation of column names that are keywords</td> </td>
--apply-slave-statements</td>Include STOP SLAVE prior to CHANGE MASTER statement and START SLAVE at end of output</td> </td>
--bind-address</td>Use specified network interface to connect to MySQL Server</td>5.6.1</td>
--character-sets-dir</td>Directory where character sets are installed</td> </td>
--comments</td>Add comments to dump file</td> </td>
--compact</td>Produce more compact output</td> </td>
--compatible</td>Produce output that is more compatible with other database systems or with older MySQL servers</td> </td>
--complete-insert</td>Use complete INSERT statements that include column names</td> </td>
--compress</td>Compress all information sent between client and server</td> </td>
--create-options</td>Include all MySQL-specific table options in CREATE TABLE statements</td> </td>
--databases</td>Interpret all name arguments as database names</td> </td>
--debug</td>Write debugging log</td> </td>
--debug-check</td>Print debugging information when program exits</td> </td>
--debug-info</td>Print debugging information, memory, and CPU statistics when program exits</td> </td>
--default-auth</td>Authentication plugin to use</td> </td>
--default-character-set</td>Specify default character set</td> </td>
--defaults-extra-file</td>Read named option file in addition to usual option files</td> </td>
--defaults-file</td>Read only named option file</td> </td>
--defaults-group-suffix</td>Option group suffix value</td> </td>
--delayed-insert</td>Write INSERT DELAYED statements rather than INSERT statements</td> </td>
--delete-master-logs</td>On a master replication server, delete the binary logs after performing the dump operation</td> </td>
--disable-keys</td>For each table, surround INSERT statements with statements to disable and enable keys</td> </td>
--dump-date</td>Include dump date as "Dump completed on" comment if --comments is given</td> </td>
--dump-slave</td>Include CHANGE MASTER statement that lists binary log coordinates of slave's master</td> </td>
--enable-cleartext-plugin</td>Enable cleartext authentication plugin</td>5.6.28</td>
--events</td>Dump events from dumped databases</td> </td>
--extended-insert</td>Use multiple-row INSERT syntax</td> </td>
--fields-enclosed-by</td>This option is used with the --tab option and has the same meaning as the corresponding clause for LOAD DATA INFILE</td> </td>
--fields-escaped-by</td>This option is used with the --tab option and has the same meaning as the corresponding clause for LOAD DATA INFILE</td> </td>
--fields-optionally-enclosed-by</td>This option is used with the --tab option and has the same meaning as the corresponding clause for LOAD DATA INFILE</td> </td>
--fields-terminated-by</td>This option is used with the --tab option and has the same meaning as the corresponding clause for LOAD DATA INFILE</td> </td>
--flush-logs</td>Flush MySQL server log files before starting dump</td> </td>
--flush-privileges</td>Emit a FLUSH PRIVILEGES statement after dumping mysql database</td> </td>
--force</td>Continue even if an SQL error occurs during a table dump</td> </td>
--help</td>Display help message and exit</td> </td>
--hex-blob</td>Dump binary columns using hexadecimal notation</td> </td>
--host</td>Host to connect to (IP address or hostname)</td> </td>
--ignore-table</td>Do not dump given table</td> </td>
--include-master-host-port</td>Include MASTER_HOST/MASTER_PORT options in CHANGE MASTER statement produced with --dump-slave</td> </td>
--insert-ignore</td>Write INSERT IGNORE rather than INSERT statements</td> </td>
--lines-terminated-by</td>This option is used with the --tab option and has the same meaning as the corresponding clause for LOAD DATA INFILE</td> </td>
--lock-all-tables</td>Lock all tables across all databases</td> </td>
--lock-tables</td>Lock all tables before dumping them</td> </td>
--log-error</td>Append warnings and errors to named file</td> </td>
--login-path</td>Read login path options from .mylogin.cnf</td>5.6.6</td>
--master-data</td>Write the binary log file name and position to the output</td> </td>
--max_allowed_packet</td>Maximum packet length to send to or receive from server</td> </td>
--net_buffer_length</td>Buffer size for TCP/IP and socket communication</td> </td>
--no-autocommit</td>Enclose the INSERT statements for each dumped table within SET autocommit = 0 and COMMIT statements</td> </td>
--no-create-db</td>Do not write CREATE DATABASE statements</td> </td>
--no-create-info</td>Do not write CREATE TABLE statements that re-create each dumped table</td> </td>
--no-data</td>Do not dump table contents</td> </td>
--no-defaults</td>Read no option files</td> </td>
--no-set-names</td>Same as --skip-set-charset</td> </td>
--no-tablespaces</td>Do not write any CREATE LOGFILE GROUP or CREATE TABLESPACE statements in output</td> </td>
--opt</td>Shorthand for --add-drop-table --add-locks --create-options --disable-keys --extended-insert --lock-tables --quick --set-charset.</td> </td>
--order-by-primary</td>Dump each table's rows sorted by its primary key, or by its first unique index</td> </td>
--password</td>Password to use when connecting to server</td> </td>
--pipe</td>On Windows, connect to server using named pipe</td> </td>
--plugin-dir</td>Directory where plugins are installed</td> </td>
--port</td>TCP/IP port number for connection</td> </td>
--print-defaults</td>Print default options</td> </td>
--protocol</td>Connection protocol to use</td> </td>
--quick</td>Retrieve rows for a table from the server a row at a time</td> </td>
--quote-names</td>Quote identifiers within backtick characters</td> </td>
--replace</td>Write REPLACE statements rather than INSERT statements</td> </td>
--result-file</td>Direct output to a given file</td> </td>
--routines</td>Dump stored routines (procedures and functions) from dumped databases</td> </td>
--secure-auth</td>Do not send passwords to server in old (pre-4.1) format</td>5.6.17</td>
--set-charset</td>Add SET NAMES default_character_set to output</td> </td>
--set-gtid-purged</td>Whether to add SET @@GLOBAL.GTID_PURGED to output</td>5.6.9</td>
--shared-memory-base-name</td>The name of shared memory to use for shared-memory connections</td> </td>
--single-transaction</td>Issue a BEGIN SQL statement before dumping data from server</td> </td>
--skip-add-drop-table</td>Do not add a DROP TABLE statement before each CREATE TABLE statement</td> </td>
--skip-add-locks</td>Do not add locks</td> </td>
--skip-comments</td>Do not add comments to dump file</td> </td>
--skip-compact</td>Do not produce more compact output</td> </td>
--skip-disable-keys</td>Do not disable keys</td> </td>
--skip-extended-insert</td>Turn off extended-insert</td> </td>
--skip-opt</td>Turn off options set by --opt</td> </td>
--skip-quick</td>Do not retrieve rows for a table from the server a row at a time</td> </td>
--skip-quote-names</td>Do not quote identifiers</td> </td>
--skip-set-charset</td>Do not write SET NAMES statement</td> </td>
--skip-triggers</td>Do not dump triggers</td> </td>
--skip-tz-utc</td>Turn off tz-utc</td> </td>
--socket</td>For connections to localhost, the Unix socket file to use</td> </td>
--ssl</td>Enable encrypted connection</td> </td>
--ssl-ca</td>File that contains list of trusted SSL Certificate Authorities</td> </td>
--ssl-capath</td>Directory that contains trusted SSL Certificate Authority certificate files</td> </td>
--ssl-cert</td>File that contains X509 certificate</td> </td>
--ssl-cipher</td>List of permitted ciphers for connection encryption</td> </td>
--ssl-crl</td>File that contains certificate revocation lists</td>5.6.3</td>
--ssl-crlpath</td>Directory that contains certificate revocation list files</td>5.6.3</td>
--ssl-key</td>File that contains X509 key</td> </td>
--ssl-mode</td>Security state of connection to server</td>5.6.30</td>
--ssl-verify-server-cert</td>Verify host name against server certificate Common Name identity</td> </td>
--tab</td>Produce tab-separated data files</td> </td>
--tables</td>Override --databases or -B option</td> </td>
--triggers</td>Dump triggers for each dumped table</td> </td>
--tz-utc</td>Add SET TIME_ZONE='+00:00' to dump file</td> </td>
--user</td>MySQL user name to use when connecting to server</td> </td>
--verbose</td>Verbose mode</td> </td>
--version</td>Display version information and exit</td> </td>
--where</td>Dump only rows selected by given WHERE condition</td> </td>
--xml</td>Produce XML output</td> </td>

主 楼 发布于:2018-01-29 17:36:23 编辑于:2018-01-29 17:42:49回复
旅行者

一个mysqldump的文档,插入到word中居然有63页,还是5号字!我也是服了...

2 楼 发布于:2018-01-29 17:55:19
回复
旅行者

上边的表格一个110个参数

3 楼 发布于:2018-01-29 17:57:06
回复
悠悠男1

麦子爱上谷子,谷子爱上桃子,桃子爱上李子,李子却爱上麦子,大家猜猜麦子是男是女!嘻嘻,猜不到的是不男不女!

4 楼 发布于:2018-02-06 07:22:21
回复
木-木

爱是一种感受,即使痛苦也会觉得幸福;爱是一种体会,即使心碎也会觉得甜蜜;爱是一种经历,即使破碎也会觉得美丽。

5 楼 发布于:2018-04-21 08:24:21
回复
下课打闹闹

鱼说:我终日将双眼睁开,是因为时时刻刻不想你离去!水说:我终日流淌,是因为时时刻刻想要拥抱你!

6 楼 发布于:2018-05-04 18:12:07
回复
冷面孤独

某大学生的最低奋斗目标,农夫,山泉,有点田

7 楼 发布于:2018-06-24 12:15:20
回复
最爱章子怡的我

语文课,老师叫起一昏睡同学回答问题,该同学迷迷糊糊啥也说不出……老师说:"你会不会呀?不会也吱一声啊!"该同学:"吱。"

8 楼 发布于:2018-07-11 03:40:10
回复
中原剑客

我怎么忍心眼睁睁看着你离去?我们一起度过了多少温馨快乐的时光,可是今天就要分手!望着你哀怨的眼神,我大喊:等一等,这狗我不卖了

9 楼 发布于:2018-08-13 18:53:10
回复
放小孩的羊

十个男生看五个女生洗澡(猜--成语)——五光十色

10 楼 发布于:2018-09-19 19:54:55
回复
绍峰

高端大气上档次,低调奢华有内涵

11 楼 发布于:2018-10-01 15:31:55
回复
冷冷清秋112

我不能给你幸福,但可以给你舒服!

12 楼 发布于:2018-12-19 18:57:37
回复
好吃懒做

我要是妞,早爱上我了……

13 楼 发布于:2019-03-06 05:57:58
回复
龙之猫猫

给你讲个故事,从前有个笨蛋,他非常笨,别人问他什么问题他都只会摇头或回答“没有”,这个故事你听过吗?

14 楼 发布于:2019-03-19 10:41:17
回复
时代的宠儿

我爱握着你那纤纤的小手,我爱拥着你那软软的躯体,爱你淘气时发亮的眼睛,爱你撒娇时微翘的双唇,也有那不讲理时蛮横的表情。对你,我已经无条件投降了,你就签下爱情合约吧不然没人要我了!!!我已准备好将权利减半、义务倍增了!

15 楼 发布于:2022-08-18 15:12:21
回复
赛西施

信春哥,得永生!

16 楼 发布于:2022-11-01 12:51:01
回复
冯建梅木

以前的喜欢只是一种经历与感觉,而不是一个证据,没有人需要为以前的喜欢付出现在或以后的责任。

17 楼 发布于:2025-05-21 22:15:07
回复

发表回复: