mysql — The MySQL Command-Line Client exit (\q) Exit mysql. Same as quit. go (\g) Send command to mysql server. help (\h) Display this help. nopager (
) Disable pager, print to stdout. notee (	) Don’t write into outfile. pager (\P) Set PAGER [to_pager]. Print the query results via PAGER. print (\p) Print current command. prompt (\R) Change your mysql prompt. quit (\q) Quit mysql. rehash (\#) Rebuild completion hash. source (\.) Execute an SQL script file. Takes a file name as an argument. status (\s) Get status information from the server. system (\!) Execute a system shell command. tee (\T) Set outfile [to_outfile]. Append everything into given outfile. use (\u) Use another database. Takes database name as argument. charset (\C) Switch to another charset. Might be needed for processing binlog with multi-byte charsets. warnings (\W) Show warnings after every statement. nowarning (\w) Don’t show warnings after every statement. resetconnection(\x) Clean session context. query_attributes(\) Sets string parameters (name1 value1 name2 value2 ...) for the next query to pick up. For server side help, type ’help contents’ If  mysql  is invoked with the  --binary-mode  option, all  mysql  commands are disabled except  charset and  delimiter  in noninteractive mode (for input piped to  mysql  or loaded using the  source  command). Each command has both a long and short form. The long form is not case-sensitive; the short form is. The long form can be followed by an optional semicolon terminator, but the short form should not. The use of short-form commands within multiple-line  /* ... */  comments is not supported. Short-form commands do work within single-line  /*! ... */  version comments, as do  /*+ ... */  optimizer-hint comments, which are stored in object definitions. If there is a concern that optimizer-hint comments may be stored in object definitions so that dump files when reloaded with  mysql  would result in execution of such commands, either invoke  mysql  with the  --binary-mode  option or use a reload client other than  mysql . Display a help message listing the available  mysql  commands. If you provide an argument to the  help  command,  mysql  uses it as a search string to access server- side help from the contents of the MySQL Reference Manual. For more information, see Section 4.5.1.4, “mysql Client Server-Side Help” . Change the default character set and issue a  SET NAMES  statement. This enables the character set to remain synchronized on the client and server if  mysql  is run with auto-reconnect enabled (which is not recommended), because the specified character set is used for reconnects. Clear the current input. Use this if you change your mind about executing the statement that you are entering. Reconnect to the server. The optional database name and host name arguments may be given to specify the default database or the host where the server is running. If omitted, the current values are used. •  help [ arg ] ,  \h [ arg ] ,  \? [ arg ] ,  ? [ arg ] •  charset  charset_name ,  \C  charset_name •  clear ,  \c •  connect [ db_name  [ host_name ]] ,  \r [ db_name  [ host_name ]] 434