How Can I Migrate Databases or Tables Whose Names Contain Uppercase Letters?
Scenarios
When the value of source database parameter lower_case_table_names is set to 1, the databases or tables whose names contain uppercase letters cannot be migrated.
Possible Cause
When the value of lower_case_table_names in the source database is 1, the MySQL engine converts the database name or table name into lowercase letters. In this case, the database or table may not be found, resulting in query failure. Simply, if the value of lower_case_table_names is 1, the database or table containing uppercase letters may be inaccessible.
Solutions
Two solutions are provided as follows:
Solution 1
Change the value of lower_case_table_names in the source database to 0 (case-sensitive) and ensure that the value of this parameter in the source database is the same as that in the destination database.
Solution 2
If the value of lower_case_table_names cannot be changed permanently, change the value to 0, and then perform the following operations:
- For a table, you can use the following statement to convert the table name to lowercase:
alter table `BigTab` rename to `bigtab`
- For a database, you need to export the database data, change the database name from uppercase to lowercase, and then import the data.
After changing the database name or table name, you need to maintain the permission consistency without affecting application access.
Solution 3
Do not migrate the databases or tables that contain uppercase letters.
Real-Time Migration FAQs
- When Can I Stop a Migration Task?
- How Do I Maintain the Original Service User Permission System After Definer Is Forcibly Converted During MySQL Migration?
- What Can I Do If the Invoking Permission Problem Occurs After the MySQL Stored Procedure Is Migrated to the Cloud?
- How Do I Ensure that All Services on the Database Are Stopped?
- What Can I Do When Message "can not get agency token" Is Displayed in the Migration Log
- What Do I Do If the Maximum Index Length Has Been Reached During Migration from Oracle to MySQL?
- Why Is the Collation of Heterogeneous or Oracle Databases Converted to utf8mb4_bin After Those Databases Are Migrated to MySQL?
- What Can I Do If MyISAM Tables Are Not Supported by RDS for MySQL?
- What Are the Precautions for Migrating Data from an Earlier Version MySQL to MySQL 8.0?
- What Can I Do When OOM Occurs During the Migration of MongoDB Databases?
- How Do I Disable the Balancer?
- How Do I Export and Import Events and Triggers in Batches?
- How Can I Migrate Databases or Tables Whose Names Contain Uppercase Letters?
- How Do I Delete Orphaned Documents in MongoDB Sharded Clusters?
- What Can I Do If There Is an Extra Backslash (\) After a MySQL Account Is Migrated?
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbotmore