MySQL 8.0.40
Source Code Documentation
mysqltest Language Reference

Table of Contents

This chapter describes the test language implemented by mysqltest. The language allows input to contain a mix of comments, commands executed by mysqltest itself, and SQL statements that mysqltest sends to a MySQL server for execution.

Terminology notes:

  • A “command” is an input test that mysqltest recognizes and executes itself. A “statement” is an SQL statement or query that mysqltest sends to the MySQL server to be executed.

  • When mysqltest starts, it opens a connection it calls default to the MySQL server, using any connection parameters specified by the command options. (For a local server, the default user name is root. For an external server, the default user name is test or the user specified with the --user option.) You can use the connect command to open other connections, the connection command to switch between connections, and the disconnect command to close connections. However, the capability for switching connections means that the connection named default need not be the connection in use at a given time. To avoid ambiguity, this document avoids the term “default connection”. It uses the term “current connection” to mean “the connection currently in use”, which might be different from “the connection named default”.