man mysql (Commandes) - text-based client for mysqld, a SQL-based relational database daemon


mysql - text-based client for mysqld, a SQL-based relational database daemon


mysql [OPTIONS] [Database]


mysql [-B|--batch] [-#|--debug= logfile] [-T|--debug-info] [-e|--exec= command] [-f|--force] [-?|--help] [-h|--host= hostname] [-n|--unbuffered] [-p[pwd]] [--password=[pwd] (INSECURE)] [-P|--port= pnum] [-q|--quick] [-r|--raw] [-s|--silent] [-S|--socket= snum] [-u|--user= uname] [-v|--verbose] [-V|--version] [-w|--wait]


The mysql program provides a curses-based interface to the SQL-based database server daemon, mysqld(1). Full fuller documentation, refer to the mysql online HTML documention at NOTE: Unfortunately this documentation is not released under a license that makes Debian able to redistribute it (not even legally!), so there is no package available with this documentation. Feel free to contact mysql if you'd like to share your opinion on the matter :)


Print results with a tab as separator, each row on a new line.
Employ the specified debug log.
Print debug information upon exiting.
-e | --exec=command
Execute the specified command and quit (--batch is implicit).
Continue even if the face of a SQL error.
Display a help message and exit.
Connect to the specified host.
Flush the buffer after each query.
Employ the specified password when connecting to the database server. If a password is not supplied, it will be requested interactively. WARNING: This is insecure as the password is visible for anyone through /proc for a short time.
Employ the specified port number for connecting to the database server.
Do not cache the result; print it row by row. This may slow down the server if the output is suspended.
Write fields without conversion. (used with --batch).
Silent mode: reduce the amount of output.
Employ the specified socket file for connecting to the database server.
Employ the specified user name for logging in to the server.
Verbose mode: write more Specifying this option twice produces a tabular output format.
Print the mysql version number and exit.
Wait and retry if the database server connection is down.


MySQL configuration file
Client executable
Server executable
executable shell script for starting mysqld safely
location of database files


You can also read a backup dump file back into MySQL with:

database < backup-file.sql


isamchk(1), isamlog(1), mysqlaccess(1), mysqladmin(1), mysqld(1), mysqld_multi(1), mysqld_safe(1), mysqldump(1), mysql_fix_privilege_tables(1), mysqlshow(1), mysql_zap(1), perror(1), replace(1)

For more information please refer to the MySQL reference manual, which may already be installed locally and which is also available online at


Please refer to to report bugs.


Ver 6.3, distribution 4.1.15 Michael (Monty) Widenius (, MySQL AB ( This software comes with no warranty. Manual page by R. P. C. Rodgers, Lister Hill National Center for Biomedical Communication, U.S. National Library of Medicine (