This page lists common error codes returned by PolarDB-X 1.0 and how to resolve them.
Error code ranges
| Range | Category |
|---|---|
| TDDL-1094, TDDL-1305 | Session management |
| TDDL-4006–4007 | Table metadata |
| TDDL-4100–4108 | Backend instance connections |
| TDDL-4200–4203 | Database shard availability and query timeouts |
| TDDL-4400–4408 | Sequences |
| TDDL-4500–4518 | SQL parsing, optimization, and validation |
| TDDL-4600–4617 | SQL execution and transactions |
| TDDL-4636, TDDL-4642 | DDL |
| TDDL-4800–4802 | Transaction IDs |
| TDDL-4994, TDDL-4998 | Request throttling and unsupported features |
| TDDL-5001–5008 | Distributed transactions |
TDDL-4006 ERR_TABLE_NOT_EXIST
The specified table does not exist.
ERR-CODE: [TDDL-4006][ERR_TABLE_NOT_EXIST] Table '*****' doesn't exist.Either the table does not exist in PolarDB-X 1.0, or PolarDB-X 1.0 failed to load the table's metadata. Verify that the table exists in PolarDB-X 1.0.
TDDL-4007 ERR_CANNOT_FETCH_TABLE_META
PolarDB-X 1.0 failed to load the metadata of a table.
ERR-CODE: [TDDL-4007][ERR_CANNOT_FETCH_TABLE_META] Table '*****' metadata
cannot be fetched because Table '*****.*****' doesn't exist.Possible causes:
The table has not been created.
The table in the database shard was manually deleted or renamed.
PolarDB-X 1.0 cannot connect to the backend ApsaraDB RDS for MySQL instances.
Check whether the table exists and verify that all backend ApsaraDB RDS for MySQL instances are running normally. If the table was manually deleted or renamed, use the data restoration feature of ApsaraDB RDS for MySQL to recover the data.
TDDL-4100 ERR_ATOM_NOT_AVALILABLE
A backend ApsaraDB RDS for MySQL instance is unavailable.
ERR-CODE: [TDDL-4100][ERR_ATOM_NOT_AVALILABLE] Atom : ***** isNotAvailableWhen PolarDB-X 1.0 detects that a backend ApsaraDB RDS for MySQL instance is unhealthy, it temporarily blocks access to that instance and returns this error. Check the status of all backend ApsaraDB RDS for MySQL instances and restore any that are abnormal.
After the instance recovers, PolarDB-X 1.0 automatically restores access to it.
TDDL-4101 ERR_ATOM_GET_CONNECTION_FAILED_UNKNOWN_REASON
PolarDB-X 1.0 failed to connect to a backend ApsaraDB RDS for MySQL instance due to an unknown reason.
ERR-CODE: [TDDL-4101][ERR_ATOM_GET_CONNECTION_FAILED_UNKNOWN_REASON] Get
connection for db '*****' from pool failed. AppName:*****, Env:*****,
UnitName:null. Message from pool: wait millis 5000, active 0, maxActive 5.
You should look for the following logs which contains the real reason.PolarDB-X 1.0 establishes backend connections asynchronously. This error is returned when the connection attempt times out and no specific error is reported by the async task. In most cases, the backend ApsaraDB RDS for MySQL instance is in an abnormal state. Check the instance status to identify the root cause.
TDDL-4102 ERR_ATOM_GET_CONNECTION_FAILED_KNOWN_REASON
PolarDB-X 1.0 failed to connect to a backend ApsaraDB RDS for MySQL instance. The error message includes the specific reason.
ERR-CODE: [TDDL-4102][ERR_ATOM_GET_CONNECTION_FAILED_KNOWN_REASON] Get
connection for db '*****' failed because wait millis 5000, active 0,
maxActive 5Possible causes:
The connection count to the backend instance reached its limit.
The connection attempt timed out.
The connection was rejected.
Check the specific reason in the error message and resolve accordingly.
TDDL-4103 ERR_ATOM_CONNECTION_POOL_FULL
The backend connection pool is full.
ERR-CODE: [TDDL-4103][ERR_ATOM_CONNECTION_POOL_FULL] Pool of DB '*****' is
full. Message from pool: wait millis 5000, active 5, maxActive 5.
AppName:*****, Env:*****, UnitName:null.Possible causes:
Slow SQL statements hold connections for extended periods, leaving insufficient connections available.
The application is not closing database connections, causing connection leaks.
A large number of cross-database queries run in parallel, each consuming multiple connections.
How to resolve:
Use a connection pooling framework such as Spring JDBC or MyBatis.
Optimize slow SQL statements based on performance analysis.
Use the read/write splitting feature of PolarDB-X 1.0 to route cross-database queries to read-only nodes.
Upgrade the ApsaraDB RDS for MySQL instance specifications to increase backend processing capacity.
TDDL-4104 ERR_ATOM_CREATE_CONNECTION_TOO_SLOW
The connection to a backend ApsaraDB RDS for MySQL instance timed out.
ERR-CODE: [TDDL-4104][ERR_ATOM_CREATE_CONNECTION_TOO_SLOW] Get connection
for db '*****' from pool timeout. AppName:*****, Env:*****,
UnitName:null. Message from pool: wait millis 5000, active 3, maxActive 5.This happens when a burst of connection requests arrives in a short period, or when establishing a single connection takes too long. The backend ApsaraDB RDS for MySQL instance is likely under heavy load. Enable the read/write splitting feature of PolarDB-X 1.0, or upgrade the ApsaraDB RDS for MySQL instance specifications.
TDDL-4105 ERR_ATOM_ACCESS_DENIED
The backend ApsaraDB RDS for MySQL instance rejected the connection from PolarDB-X 1.0.
ERR-CODE: [TDDL-4105][ERR_ATOM_ACCESS_DENIED] DB '*****' Access denied for
user '*****'@'*****'. AppName:*****, Env:*****, UnitName:null. Please
contact DBA to check.This error occurs when the username or password that PolarDB-X 1.0 auto-generated for the backend instance has been manually changed. It also occurs when the backend ApsaraDB RDS for MySQL instance has expired or the account has an overdue payment. Renew the instance or settle the payment to restore access.
TDDL-4106 ERR_ATOM_DB_DOWN
PolarDB-X 1.0 cannot connect to a backend ApsaraDB RDS for MySQL instance.
ERR-CODE: [TDDL-4106][ERR_ATOM_DB_DOWN] DB '*****' cannot be connected.
AppName:*****, Env:*****, UnitName:null. It seems a very real possibility
that this DB IS DOWN. Please contact DBA to check.The connection attempt timed out or received no response, which typically indicates the backend ApsaraDB RDS for MySQL instance has failed. Check the instance status and restore it.
TDDL-4108 ERR_VARIABLE_CAN_NOT_SET_TO_NULL_FOR_NOW
A MySQL variable cannot be set to NULL.
ERR-CODE: [TDDL-4108][ERR_VARIABLE_CAN_NOT_SET_TO_NULL_FOR_NOW] System
variable ***** can't set to null for now;Some MySQL system variables do not accept NULL as a value. When a SET statement attempts to assign NULL to such a variable, PolarDB-X 1.0 returns this error. Check the variable's valid values in the MySQL server system variables documentation and assign a valid value.
TDDL-4200 ERR_GROUP_NOT_AVALILABLE
A PolarDB-X 1.0 database shard is unavailable.
ERR-CODE: [TDDL-4200][ERR_GROUP_NOT_AVALILABLE] The TDDL Group ***** is
running in fail-fast status, caused by this SQL:***** which threw a fatal
exception as *****.When all backend ApsaraDB RDS for MySQL instances for a database shard become inaccessible, PolarDB-X 1.0 sets the shard to fail-fast state. Troubleshoot the backend instance failure based on the error information. After the instance recovers, PolarDB-X 1.0 automatically exits the fail-fast state.
TDDL-4201 ERR_GROUP_NO_ATOM_AVALILABLE
No ApsaraDB RDS for MySQL instances are available for a database shard.
ERR-CODE: [TDDL-4201][ERR_GROUP_NO_ATOM_AVALILABLE] All weights of DBs in
Group '*****' is 0. Weights is: *****.All backend instances for the shard are unavailable, or the shard is in fail-fast state. Check the status of all backend ApsaraDB RDS for MySQL instances and restore any that have failed.
TDDL-4202 ERR_SQL_QUERY_TIMEOUT
A query timed out on the backend ApsaraDB RDS for MySQL instances.
ERR-CODE: [TDDL-4202][ERR_SQL_QUERY_TIMEOUT] Slow query leads to a timeout
exception, please contact DBA to check slow sql. SocketTimout:*** ms,
Atom:*****, Group:*****, AppName:*****, Env:*****, UnitName:null.The SQL statement execution time exceeded the socketTimeout value of the PolarDB-X 1.0 instance (default: 900 seconds). Optimize the SQL statement and add suitable indexes on the backend instances to improve query performance.
If the error persists after optimization, use a hint to set a temporary timeout for the specific statement:
/*TDDL:SOCKET_TIMEOUT=900000*/ SELECT * FROM dual;The SOCKET_TIMEOUT value is in milliseconds. For more information, see Specify a custom time-out period for an SQL statement.
TDDL-4203 ERR_SQL_QUERY_MERGE_TIMEOUT
A distributed query timed out while merging results.
ERR-CODE: [TDDL-4203][ERR_SQL_QUERY_MERGE_TIMEOUT] Slow sql query leads to
a timeout exception during merging results, please optimize the slow sql.
The the default timeout is *** ms. DB is *****The query scanned data across multiple database shards and exceeded the default timeout of 900 seconds. To optimize the query:
Include the shard key in the
WHEREclause to limit execution to a specific shard.Add suitable indexes on the backend ApsaraDB RDS for MySQL instances.
Eliminate expensive distributed operations such as cross-database JOIN queries and result resorting.
If the error persists, use a hint to set a temporary timeout:
/*TDDL:SOCKET_TIMEOUT=900000*/ SELECT * FROM dual;The SOCKET_TIMEOUT value is in milliseconds. For more information, see Specify a custom time-out period for an SQL statement.
TDDL-4400 ERR_SEQUENCE
Sequence processing failed.
ERR-CODE: [TDDL-4400][ERR_SEQUENCE] Sequence : All dataSource faild to get value!PolarDB-X 1.0 failed to process the sequence. The specific error message follows Sequence :. This typically means a backend ApsaraDB RDS for MySQL instance failure has made the sequence-related tables inaccessible. Check the status of all backend instances.
TDDL-4401 ERR_MISS_SEQUENCE
The specified sequence does not exist.
ERR-CODE: [TDDL-4401][ERR_MISS_SEQUENCE] Sequence '*****' is not foundRun SHOW SEQUENCES to list all sequences in PolarDB-X 1.0 and verify the sequence name. If the sequence does not exist, create it:
CREATE SEQUENCE <sequence_name> [ START WITH <value> ]
[ INCREMENT BY <value> ] [ MAXVALUE <value> ]
[ CYCLE | NOCYCLE ]For more information, see Sequence.
TDDL-4403 ERR_MISS_SEQUENCE_TABLE_ON_DEFAULT_DB
The sequence table does not exist in the default database.
ERR-CODE: [TDDL-4403][ERR_MISS_SEQUENCE_TABLE_ON_DEFAULT_DB] Sequence table
is not in default db.The sequence or sequence_opt table cannot be found in the backend database.
TDDL-4404 ERR_SEQUENCE_TABLE_META
The sequence table schema is invalid.
ERR-CODE: [TDDL-4404][ERR_SEQUENCE_TABLE_META] the meta of sequence table
is error, some columns missedRequired columns are missing from the sequence or sequence_opt table.
TDDL-4405 ERR_INIT_SEQUENCE_FROM_DB
Sequence initialization failed.
ERR-CODE: [TDDL-4405][ERR_INIT_SEQUENCE_FROM_DB] init sequence manager
error: *****PolarDB-X 1.0 failed to initialize the sequence. The specific error follows init sequence manager error:. Check the status of all backend ApsaraDB RDS for MySQL instances.
TDDL-4407 ERR_OTHER_WHEN_BUILD_SEQUENCE
The sequence table is inaccessible.
ERR-CODE: [TDDL-4407][ERR_OTHER_WHEN_BUILD_SEQUENCE] error when build
sequence: *****An error occurred while accessing the sequence or sequence_opt table. The specific error follows error when build sequence:. Check the status of all backend ApsaraDB RDS for MySQL instances.
DDL-4408 ERR_SEQUENCE_NEXT_VALUE
Failed to get the next value from a sequence.
ERR-CODE: [TDDL-4408][ERR_SEQUENCE_NEXT_VALUE] error when get sequence's
next value, sequence is: *****, error: *****This error occurs when retrieving a sequence value via a PolarDB-X 1.0 auto-increment primary key or the <sequence_name>.NEXTVAL syntax. The specific error follows error:. In most cases, a backend ApsaraDB RDS for MySQL instance has failed or is under excessive load. Check the status and workload of all backend instances.
TDDL-4500 ERR_PARSER
The SQL statement could not be parsed.
ERR-CODE: [TDDL-4500][ERR_PARSER] not support statement: '*****'PolarDB-X 1.0 supports SQL-92 standard syntax and MySQL-compatible extensions. Check whether the statement complies with the SQL syntax and MySQL specifications supported by PolarDB-X 1.0. For reference, see SQL limits and the standard SQL syntax reference.
TDDL-4501 ERR_OPTIMIZER
The optimizer failed to process the SQL statement.
ERR-CODE: [TDDL-4501][ERR_OPTIMIZER] optimize error by: Unknown column
'*****' in 'order clause'The SQL optimizer converts statements into an internal syntax tree. A logic error in the statement prevents this conversion. The specific error follows optimize error by:. Correct the statement based on the error description.
TDDL-4502 ERR_OPTIMIZER_MISS_ORDER_FUNCTION_IN_SELECT
A column returned by a function in the ORDER BY clause is missing from the SELECT clause.
ERR-CODE: [TDDL-4502][ERR_OPTIMIZER_MISS_ORDER_FUNCTION_IN_SELECT] Syntax
Error: orderBy/GroupBy Column ***** is not existed in select clauseIn PolarDB-X 1.0, when the ORDER BY clause contains a function that returns columns (such as RAND()), those columns must also appear in the SELECT clause. Add the missing columns to the SELECT clause.
TDDL-4504 ERR_OPTIMIZER_SELF_CROSS_JOIN
A SELF JOIN query is missing the required shard key conditions.
ERR-CODE: [TDDL-4504][ERR_OPTIMIZER_SELF_CROSS_JOIN] self cross join case,
add shard column filter on right tableFor SELF JOIN queries, the WHERE clause must include the shard key of both the left table and the right table. Add both shard keys to the WHERE clause.
TDDL-4506 ERR_MODIFY_SHARD_COLUMN
Shard keys cannot be updated with UPDATE.
ERR-CODE: [TDDL-4506][ERR_MODIFY_SHARD_COLUMN] Column '*****' is a sharding
key of table '*****', which is forbidden to be modified.Updating a shard key with UPDATE would move data between shards, which PolarDB-X 1.0 cannot do atomically. Use a DELETE followed by INSERT to achieve the same result.
TDDL-4508 ERR_OPTIMIZER_NOT_ALLOWED_SORT_MERGE_JOIN
The sort-merge join operation cannot run because equivalent join conditions are missing.
ERR-CODE: [TDDL-4508][ERR_OPTIMIZER_NOT_ALLOWED_SORT_MERGE_JOIN] sort merge
join is not allowed when missing equivalent filterWhen tables in a JOIN query reside in different ApsaraDB RDS for MySQL instances, PolarDB-X 1.0 uses the sort-merge join algorithm, which requires equivalent conditions on both the left and right tables. Add matching JOIN or WHERE conditions for both tables.
TDDL-4509 ERR_OPTIMIZER_ERROR_HINT
The hint syntax is invalid.
ERR-CODE: [TDDL-4509][ERR_OPTIMIZER_ERROR_HINT] Hint Syntax Error:
unexpected operation: *****.PolarDB-X 1.0 cannot parse the hint in the SQL statement. For correct hint syntax, see the hints overview.
TDDL-4510 ERR_CONTAINS_NO_SHARDING_KEY
The SQL statement is missing the required shard key.
ERR-CODE: [TDDL-4510][ERR_CONTAINS_NO_SHARDING_KEY] Your SQL contains NO
SHARDING KEY '*****' for table '*****', which is not allowed in DEFAULT.If the full table scan feature is disabled for a table, every query must include the shard key in the WHERE clause. Full table scan is enabled by default when PolarDB-X 1.0 creates a table. If it was manually disabled, include the shard key in all queries that access the table.
TDDL-4511 ERR_INSERT_CONTAINS_NO_SHARDING_KEY
The INSERT statement is missing the shard key.
ERR-CODE: [TDDL-4511][ERR_INSERT_CONTAINS_NO_SHARDING_KEY] Your INSERT SQL
contains NO SHARDING KEY '*****' for table '*****'.When inserting data into a sharded table, the INSERT statement must include the shard key unless the shard key is an auto-increment primary key. Add the shard key to the INSERT statement.
TDDL-4515 ERR_CONNECTION_CHARSET_NOT_MATCH
The connection character set does not support the characters used in the statement.
ERR-CODE: [TDDL-4515][ERR_CONNECTION_CHARSET_NOT_MATCH] Caused by MySQL's
character_set_connection doesn't match your input charset. Partition DDL can
only take ASCII or chinese column name. If you want use chinese table or
column name, Make sure MySQL connection's charset support chinese character.
Use "set names xxx" to set correct charset.PolarDB-X 1.0 supports Chinese characters in table and column names. This error occurs when character_set_connection is set to a character set that does not support Chinese characters (for example, latin1).
Check the current character set:
SHOW VARIABLES LIKE 'character_set_connection';Switch to a character set that supports Chinese characters:
SET NAMES <charset>;If you connect via Java Database Connectivity (JDBC), set the characterEncoding parameter in the connection string instead.
TDDL-4516 ERR_TRUNCATED_DOUBLE_VALUE_OVERFLOW
A floating-point to integer conversion overflowed.
ERR-CODE: [TDDL-4516][ERR_TRUNCATED_DOUBLE_VALUE_OVERFLOW] Truncated
incorrect DOUBLE value '*****' over column[*****]'s value range.The result of converting a floating-point number to an integer falls outside the valid range of the target column. Check the data types of the affected columns and the input parameters in the SQL statement.
TDDL-4517 ERR_MODIFY_SYSTEM_TABLE
System tables cannot be modified.
ERR-CODE: [TDDL-4517][ERR_MODIFY_SYSTEM_TABLE] Table '*****' is PolarDB-XSYSTEM
TABLE, which is forbidden to be modified.PolarDB-X 1.0 reserves the following system tables, which cannot be modified: sequence, sequence_opt, txc_undo_log, and __DRDS__SYSTEM__LOCK__. Do not use these names when creating tables for business data.
TDDL-4518 ERR_VALIDATE
Metadata validation failed.
ERR-CODE: [TDDL-4518][ERR_VALIDATE] Object 'optest1' not foundWhen a compute node receives a SQL statement, it validates the statement against existing metadata. This error means the referenced table or column does not match the stored metadata. Verify that the table and column names in the statement are correct.
TDDL-4600 ERR_FUNCTION
A function call failed.
ERR-CODE: [TDDL-4600][ERR_FUNCTION] function compute error by Incorrect
parameter count in the call to native function '*****'The SQL statement uses invalid syntax or passes invalid parameters to a function. Check that the number and data types of the parameters match the function's requirements.
TDDL-4601 ERR_EXECUTOR
An unexpected error occurred during SQL execution.
ERR-CODE: [TDDL-4601][ERR_EXECUTOR] only one column is supported in
distinct aggregateIn most cases, an abnormal backend ApsaraDB RDS for MySQL instance caused this error. Check the status of all backend instances.
TDDL-4602 ERR_CONVERTOR
A data type conversion failed.
ERR-CODE: [TDDL-4602][ERR_CONVERTOR] convertor error by Unsupported convert:
[*****]PolarDB-X 1.0 could not convert a data type during SQL execution. Check whether the SQL statement relies on implicit type conversion and use explicit values of the same type instead.
TDDL-4603 ERR_ACCROSS_DB_TRANSACTION
A cross-database transaction is not supported under the current transaction policy.
ERR-CODE: [TDDL-4603][ERR_ACCROSS_DB_TRANSACTION] Transaction accross db is
not supported in current transaction policy, transaction node is: {0}, but
this sql execute on: *****.PolarDB-X 1.0 supports only single-database transactions. All SQL statements within a transaction must route to the same ApsaraDB RDS for MySQL database shard. Ensure that forwarding rules route all statements in the transaction to the same shard.
TDDL-4604 ERR_CONCURRENT_TRANSACTION
Nested transactions are not supported.
ERR-CODE: [TDDL-4604][ERR_CONCURRENT_TRANSACTION] Concurrent query is not
supported on transaction group, transaction group is: {0}.PolarDB-X 1.0 does not support nested transactions. Starting more than one transaction at a time over the same connection triggers this error. Abstract transaction management into a framework at the application layer to prevent nested transactions.
TDDL-4606 ERR_QUERY_CANCLED
The SQL statement was canceled.
ERR-CODE: [TDDL-4606][ERR_QUERY_CANCLED] Getting connection is not allowed
when query has been cancled, group is *****A KILL statement canceled the executing SQL statement. If this error occurs frequently, check whether a client or application is issuing KILL statements.
TDDL-4607 ERR_INSERT_WHEN_UPDATE
The internal DELETE and INSERT operation that replaces an UPDATE on a shard key failed.
ERR-CODE: [TDDL-4607][ERR_INSERT_WHEN_UPDATE] Insert new values error,
table is: *****, old Values: *****, new Values: *****When the shard key update feature is enabled, PolarDB-X 1.0 rewrites shard key UPDATE statements as DELETE and INSERT operations. In most cases, this error means a backend ApsaraDB RDS for MySQL instance has failed. Check the status of all backend instances.
TDDL-4610 ERR_CONNECTION_CLOSED
The connection is closed.
ERR-CODE: [TDDL-4610][ERR_CONNECTION_CLOSED] connection has been closedAfter a statement in a transaction fails or a KILL statement cancels it, PolarDB-X 1.0 closes the connection. Subsequent statements on the same connection return this error. Close the connection and open a new one.
TDDL-4636 ERR_DDL_JOB_ERROR
The DDL statement failed.
ERR-CODE: [PXC-4636][ERR_DDL_JOB_ERROR] xxxxFor troubleshooting steps, see Handle DDL exceptions.
TDDL-4642 ERR_UNKNOWN_TABLE
The table does not exist in the database.
ERR-CODE: [PXC-4642][ERR_UNKNOWN_TABLE] Unknown table XX.XXVerify that the table exists in the current database.
TDDL-1305 ERR_UNKNOWN_SAVEPOINT
The specified savepoint does not exist.
ERR-CODE: [TDDL-1305][ERR_UNKNOWN_SAVEPOINT] SAVEPOINT ***** does not existThis error is returned when a ROLLBACK TO SAVEPOINT or RELEASE SAVEPOINT statement references a savepoint that was never created. Check the savepoint name used in the SAVEPOINT statement.
TDDL-1094 ERR_UNKNOWN_THREAD_ID
The session ID in the KILL statement does not exist.
ERR-CODE: [TDDL-1094][ERR_UNKNOWN_THREAD_ID] Unknown thread id: *****The specified session ID does not exist, or the SQL statement has already finished. Run SHOW PROCESSLIST to get the current session ID of the target statement, then use that ID in the KILL statement.
TDDL-4612 ERR_CHECK_SQL_PRIV
Insufficient permissions to execute the SQL statement.
ERR-CODE: [TDDL-4612][ERR_CHECK_SQL_PRIV] check user ***** on db *****
sql privileges failed.PolarDB-X 1.0 uses an account and permission system similar to MySQL's. The account used to run the statement lacks the required permissions. Check the account's permissions on the PolarDB-X 1.0 database and grant the necessary permissions in the PolarDB-X 1.0 console.
TDDL-4613 ERR_INSERT_SELECT
An INSERT ... SELECT statement failed.
ERR-CODE: [TDDL-4613][ERR_INSERT_SELECT] insert error, table is: *****,
values: *****PolarDB-X 1.0 splits cross-database INSERT ... SELECT statements into separate SELECT and batch INSERT operations. In most cases, this error means a backend ApsaraDB RDS for MySQL instance has failed. Check the status of all backend instances.
TDDL-4614 ERR_EXECUTE_ON_MYSQL
An error occurred when PolarDB-X 1.0 executed the SQL statement on a backend ApsaraDB RDS for MySQL instance.
ERR-CODE: [TDDL-4614][ERR_EXECUTE_ON_MYSQL] Error occurs when execute on
GROUP '*****': Duplicate entry '*****' for key 'PRIMARY'The end of the error message contains the error returned directly from the backend instance. Common backend errors include:
| Backend error | Meaning |
|---|---|
Duplicate entry '*****' for key 'PRIMARY' | A primary key conflict occurred when writing to the table. |
The table '*****' is full | The temporary table used by ApsaraDB RDS for MySQL is full. Resize the temporary table or optimize the SQL statement. |
Deadlock found when trying to get lock; | A deadlock occurred due to concurrent write transaction conflicts. |
Resolve the issue based on the specific backend error message. For reference, see the MySQL 5.6 error handling documentation.
TDDL-4615 ERR_CROSS_JOIN_SIZE_PROTECTION
The number of rows returned from the right table in a distributed JOIN query exceeded the limit.
ERR-CODE: [TDDL-4615][ERR_CROSS_JOIN_SIZE_PROTECTION] across join table
size protection, check your sql or enlarge the limination size.When PolarDB-X 1.0 runs a distributed JOIN query using nested loop join, large result sets from the right table consume significant memory and affect stability. The default limit is 5,000 rows from the right table.
Optimize the SQL statement to reduce the result set from the right table, or use the sort-merge join algorithm instead.
If you must raise the limit for a specific statement, consider the memory implications:
At 100 KB per row and 5,000 rows, the join requires 500 MB of memory.
Running the same query over five simultaneous connections requires 2.5 GB.
Do not raise the limit for records larger than 100 KB.
To override the limit for a specific statement, prepend a hint:
/*!TDDL:MAX_ROW_RETURN_FROM_RIGHT_INDEX_NESTED_LOOP=5100*/ SELECT ...TDDL-4616 ERR_UNKNOWN_DATABASE
The specified database name is invalid.
ERR-CODE: [TDDL-4616][ERR_UNKNOWN_DATABASE] Unknown database '*****'The database name in the DDL statement does not match the database name provided by PolarDB-X 1.0. Update the DDL statement to use the correct database name.
TDDL-4617 ERR_SUBQUERY_LIMIT_PROTECTION
The number of rows returned by a subquery exceeded the limit.
ERR-CODE: [TDDL-4617][ERR_SUBQUERY_LIMIT_PROTECTION] The number of rows
returned by the subquery exceeds the maximum number of 20000.When a subquery returns more than 20,000 rows, PolarDB-X 1.0 blocks execution to protect system stability. Optimize the subquery to reduce its result set, or rewrite it as a JOIN query so PolarDB-X 1.0 can use a more efficient algorithm such as sort-merge join.
TDDL-4800 ERR_SET_TXCID
The SET TXC_ID statement failed.
ERR-CODE: [TDDL-4800][ERR_SET_TXCID] set txc_id failed: *****TDDL-4801 ERR_TXCID_NULL
The SELECT LAST_TXC_ID statement returned NULL.
ERR-CODE: [TDDL-4801][ERR_TXCID_NULL] txc_xid is null: *****TDDL-4802 ERR_SELECT_LAST_TXCID
The SELECT LAST_TXC_ID statement failed.
ERR-CODE: [TDDL-4802][ERR_SELECT_LAST_TXCID] select last_txc_xid failed: *****TDDL-4994 ERR_FLOW_CONTROL
Request throttling was triggered.
ERR-CODE: [TDDL-4994][ERR_FLOW_CONTROL] [*****] flow control by *****The number of SQL requests processed by PolarDB-X 1.0 reached its limit and the current request was rejected. Check whether the peak request rate is within the expected range.
TDDL-4998 ERR_NOT_SUPPORT
The SQL syntax or feature is not supported.
ERR-CODE: [TDDL-4998][ERR_NOT_SUPPORT] ***** not support yet!The SQL syntax or feature you are using is not supported by PolarDB-X 1.0.
TDDL-5001 ERR_TRANS
A transaction error occurred.
ERR-CODE: [TDDL-5001][ERR_TRANS] Too many lines updated in statement.Resolve the error based on the specific message:
`Too many lines updated in statement`: The
UPDATEstatement exceeds the 1,000-row limit. Check theWHEREclause. To update more rows in a single transaction, use the/*TDDL:UNDO_LOG_LIMIT={number}*/hint to raise the limit.`Deferred execution is only supported in Flexible or XA Transaction`: The deferred execution feature (
/*TDDL:DEFER*/) requires the transaction policy to be set to Flexible or XA. Run the following statement to switch the policy before using deferred execution:SET drds_transaction_policy = <policy>;
TDDL-5002 ERR_TRANS_UNSUPPORTED
The syntax or feature used in the transaction is not supported.
ERR-CODE: [TDDL-5002][ERR_TRANS_UNSUPPORTED] Table without primary keys is not
supported.The feature or syntax is not supported for PolarDB-X 1.0 transactions.
TDDL-5003 ERR_TRANS_LOG
Transaction logs are inaccessible.
ERR-CODE: [TDDL-5003][ERR_TRANS_LOG] Failed to update transaction state: *****During a distributed transaction, PolarDB-X 1.0 writes transaction logs to backend ApsaraDB RDS for MySQL instances to ensure atomicity. This error means reading or writing the transaction log failed. Check the status and workload of all backend instances.
TDDL-5004 ERR_TRANS_NOT_FOUND
The specified transaction ID does not exist.
ERR-CODE: [TDDL-5008][ERR_TRANS_TERMINATED] Current transaction was killed
or timeout. You may need to set a longer timeout value.The specified transaction was terminated by a KILL statement or timed out. The timeout period is controlled by the drds_transaction_timeout parameter.
If this error is returned due to a transaction timeout, increase the timeout value:
SET drds_transaction_timeout = <value_in_milliseconds>;TDDL-5006 ERR_TRANS_COMMIT
PolarDB-X 1.0 failed to commit a transaction.
ERR-CODE: [TDDL-5006][ERR_TRANS_COMMIT] Failed to commit primary group *****:
*****, TRANS_ID = *****When a commit fails, the transaction is automatically rolled back. TRANS_ID is the transaction ID. In most cases, the underlying cause is a backend ApsaraDB RDS for MySQL instance failure. Check the status and workload of all backend instances.
TDDL-5007 ERR_TRANS_PARAM
The transaction parameter value is invalid.
ERR-CODE: [TDDL-5007][ERR_TRANS_PARAM] Illegal timeout value: *****A transaction parameter was set to an invalid value. For example, drds_transaction_timeout was set to a negative number. Check the valid value range for the parameter and set it correctly.
TDDL-5008 ERR_TRANS_TERMINATED
The transaction was killed or timed out.
ERR-CODE: [TDDL-5008][ERR_TRANS_TERMINATED] Current transaction was killed
or timeout. You may need to set a longer timeout value.The transaction was terminated by a KILL statement or exceeded the timeout set by drds_transaction_timeout. If the cause is a timeout, increase the timeout value:
SET drds_transaction_timeout = <value_in_milliseconds>;