Lightning Importing MySQL Data Exported by Dumpling Reports Error 1273 (HY000)

This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: Lightning导入dumpling导出的mysql数据报 Error 1273 (HY000)

| username: TiDBer_bvRCUSMq

[TiDB Usage Environment] Testing
[TiDB Version] 5.4.2
[Reproduction Path] Exported data from MySQL using dumping, then imported the data into TiDB using lighting
[Encountered Issue: Problem Phenomenon and Impact]
The content in the nohup.out log is as follows:
tidb lightning encountered error: [Lightning:Restore:ErrCreateSchema]create schema failed, table: db_oms1.``, stmt: restore database schema: run create schema job failed: Error 1273 (HY000): Unsupported collation when new collation is enabled: ‘utf8mb4_0900_ai_ci’

Is it that TiDB does not support this character set encoding?
[Resource Configuration]
[Attachment: Screenshot/Log/Monitoring]

| username: caiyfc | Original post link

The character sets and collations supported by TiDB version 5.4 can be referenced here:
Character Sets and Collations | PingCAP Documentation Center

| username: liuis | Original post link

Character set not supported

| username: 我是咖啡哥 | Original post link

Is it possible to create the table first and then synchronize?

| username: xingzhenxiang | Original post link

No need, Lightning will complete the database and table creation.

| username: TiDBer_pkQ5q1l0 | Original post link

In MySQL 8.0, the default character set for utf8mb4 is utf8mb4_0900_ai_ci, which is not supported by TiDB. It is best to use sed to replace the schema before importing.

| username: 小气鬼1105 | Original post link

show collation;

Check the character sets and collations supported by TiDB.

| username: xingzhenxiang | Original post link

Since there is already a best answer, there’s no need to reply, right?

| username: system | Original post link

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.