Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Issue with MySQL Source in Google Cloud DTS Due to Hyphenated Database Name

I’m trying to configure a Data Transfer Service (DTS) job in Google Cloud with a MySQL source, but the setup fails, and I suspect it’s because the source database name contains a hyphen (-).

Does Google Cloud DTS support MySQL databases with hyphens in their names? If not, what is the recommended workaround to transfer data from such databases?

0 1 28
1 REPLY 1

Hi @boc_2850,

Welcome to Google Cloud Community!

Based on the BigQuery dataset naming guidelines, BigQuery doesn’t allow hyphens in dataset names because they can interfere with SQL parsing. To work around this, you could either rename your databases to use underscores instead of hyphens, or you may try to automate the naming process using a custom script or the BigQuery API to handle the transfer without needing to rename everything manually. Just keep in mind that dataset names must start with a letter and only contain letters, numbers, and underscores, so sticking to those conventions will help ensure smooth transfers.

Was this helpful? If so, please accept this answer as “Solution”. If you need additional assistance, reply here within 2 business days and I’ll be happy to help.