This topic describes the error messages for MySQL tenants in OceanBase Database.
Format of error messages
OceanBase Database is highly compatible with MySQL. Specifically, OceanBase Database is compatible with general MySQL features, foreground and background MySQL protocols, as well as some native error codes of MySQL. Therefore, the error message format for MySQL tenants in OceanBase Database is the same as that in MySQL databases.
Format of error messages:
ERROR <err_num> (<sql_stat>): err_msg
Parameters:
err_num: the error code.sql_stat: the SQL state.err_msg: the error message.
Variables in error messages
In OceanBase Database, variables are embedded in error messages to help you troubleshoot issues. In this topic, these variables are represented by percent signs (%).
Examples:
ERROR 4626 (HY000): resource pool '%s' has already been granted to a tenant
The preceding error message may appear as the following message:
ERROR 4626 (HY000): resource pool 'pool1' has already been granted to a tenant
Error code description
The following table describes the system error codes by range.
| Error code range | Description |
|---|---|
| 0001 ~ 3999 | Error codes compatible with MySQL.
|
| 4000 ~ 4499 | Common error codes. |
| 4500 ~ 4999 | RootService error codes. |
| 5000 ~ 5999 | SQL, WITH clause, and Factoring error codes. |
| 6000 ~ 6999 | Transaction, multi-version concurrency control (MVCC), and clog error codes. |
| 7000 ~ 7999 | Election module error codes. |
| 8000 ~ 8999 | Fatal error codes. If a client receives an error message with an error code within this range, the client must close the SQL connection. |
| 9000 ~ 9499 | Backup, recovery, and STORAGE 3.0 error codes. |
| 9500 ~ 9999 | Procedural language (PL) error codes. |
| 22998, 30926, 38104, and 38105 | BLOB and CLOB error codes. |