Updated on 2025-12-11 GMT+08:00

MySQL Configuration

MySQL parameters are used to customize rules for MySQL and BigQuery script migration.

Open the features-mysql.properties file in the config folder and configure Parameters in the features-mysql.properties file as required.

Table 1 Parameters in the features-mysql.properties file

Parameter

Description

Value Range

Default Value

Example

  • table.databaseAsSchema
  • table.defaultSchema

Whether to use a database name as the schema name. If a database name does not exist, the user-defined schema specified by table.schema will be used. If table.schema is not specified, the default schema will be used.

  • true
  • false
  • public
  • true
  • public
  • table.databaseAsSchema=true
  • table.defaultSchema=public
  • table.schema

Name of the user-defined schema. If this parameter is specified, it will be directly used. In this case, even if useDatabaseAsSchema is set to true, the name of the current schema will be used.

  • schemaName
  • null
  • table.schema=
  • table.orientation

Default data storage mode. Value ROW means row storage, and value COLUMN means column storage.

  • ROW
  • COLUMN
  • ROW
  • table.orientation=ROW
  • table.type

Default table type, which can be partitioned table, replication table, or round-robin table. REPLICATION, HASH, and ROUND-ROBIN

  • HASH
  • REPLICATION
  • ROUND-ROBIN
  • HASH
  • table.type=HASH
  • table.tablespace

Tablespace options

  • COMMENT
  • RESERVE
  • RESERVE
  • table.tablespace=RESERVE
  • table.partition-key.choose.strategy

Policy for selecting the partition key

  • partitionKeyChooserStrategy
  • partitionKeyChooserStrategy
  • table.partition-key.choose.strategy=partitionKeyChooserStrategy
  • table.partition-key.name

Partition key. If this parameter is not specified, the default selection policy will be used. If there are multiple columns, separate them with commas (,). The column names are case insensitive.

  • Reserved parameter
  • null
  • table.partition-key.name=
  • table.compress.mode

Compression mode. If keyword COMPRESS is specified in CREATE TABLE, the compression feature will be triggered in the case of bulk INSERT operations. If this feature is enabled, a scan will be performed on all tuple data within the page to generate a dictionary and then the tuple data will be compressed and stored. If NOCOMPRESS is used, tables will not be compressed.

  • COMPRESS
  • NOCOMPRESS
  • NOCOMPRESS
  • table.compress.mode=NOCOMPRESS
  • table.compress.row

  • table.compress.column

Compression level of table data. It determines the compression ratio and duration.

  • YES
  • NO

  • YES
  • NO
  • LOW
  • MIDDLE
  • HIGH
  • NO

  • LOW
  • table.compress.row=NO

  • table.compress.column=LOW
  • table.compress.level

Table data compression ratio and duration at the same compression level. This divides a compression level into sublevels, providing more choices for the compression ratio and duration. As the value becomes larger, the compression ratio becomes higher and duration longer at the same compression level.

  • 0
  • 1
  • 2
  • 3
  • 0
  • table.compress.level=0
  • table.database.template

Database template

  • Reserved parameter
  • template0

table.database.template=template0

  • table.database.encoding

A database code.

  • UTF8
  • SQL_ASCII
  • GBK
  • Latin1 codes
  • UTF8

table.database.encoding=UTF8

  • table.index.rename

Whether to rename an index during its creation.

  • true
  • false
  • false

table.index.rename=false

  • table.database.onlyFullGroupBy

Whether all non-aggregated columns in a SELECT statement are included in the GROUP BY clause.

  • true
  • false
  • true

table.database.onlyFullGroupBy=true

  • table.database.realAsFloat

This parameter allows you to convert the REAL data type. By default, it is set to false, which means that the data type is converted to DOUBLE PRECISION. However, if you set it to true, the data type will be converted to REAL.

  • true
  • false
  • false

table.database.realAsFloat=false

  • table.database.havingAddGroupBy

Whether to add GROUP BY to the having clause.

  • true
  • false
  • true

table.database.havingAddGroupBy=true

  • table.function.uuid

Whether the UUID function is output as the original statement function.

  • false: The function is converted to the sys_uuid function.
  • true: The UUID function is output.

The default value is false.

  • true
  • false
  • false

table.function.uuid=false

  • table.function.split

Split function.

  • true: The split function is output.
  • false: The function is converted to the split_part function.
  • true
  • false
  • true

table.function.split=true

  • table.function.tryCast

Whether the try_cast function is output as the original statement function.

  • false (default value): The function is converted to the cast function.
  • true: The try_cast function is output.
  • true
  • false
  • false

table.function.tryCast=false

  • table.sql.set.names

Whether the setNames statement is commented out and is not converted.

  • true (default value): The statement is commented out and is not converted.
  • false: The statement is converted.
  • true
  • false
  • true

table.sql.set.names=true

  • table.sql.set.password

Whether the setPassword statement is commented out and is not converted.

  • true (default value): The statement is commented out and is not converted.
  • false: The statement is converted.
  • true
  • false
  • true

table.sql.set.password=true

  • table.sql.set.resource.group

Whether the setResourceGroup statement is commented out and is not converted.

  • true (default value): The statement is commented out and is not converted.
  • false: The statement is converted.
  • true
  • false
  • true

table.sql.set.resource.group=true

  • table.sql.set.role

Whether the setRole statement is commented out and is not converted.

  • true (default value): The statement is commented out and is not converted.
  • false: The statement is converted.
  • true
  • false
  • true

table.sql.set.role=true

  • table.sql.set.variable

Whether the setVariable statement is commented out and is not converted.

  • true (default value): The statement is commented out and is not converted.
  • false: The statement is converted.
  • true
  • false
  • true

table.sql.set.variable=true

  • sql.conversion.type

Conversion type of the SQL file. The value can be ddl or plsql.

The default value is ddl. When a stored procedure or user-defined function is executed, plsql is used.

  • ddl
  • plsql
  • ddl

sql.conversion.type=ddl

  • table.insert.convert.upsert

How to handle primary key or unique index conflicts during insertion.

  • true (update): When a conflict occurs, the existing record is updated with the new data.
  • false (ignore): When a conflict occurs, the new data is discarded and the original data is retained.
  • true
  • false
  • false

table.insert.convert.upsert=false

  • table.alter.add.index

Whether to support the ALTER TABLE... ADD INDEX conversion. false (default value): The conversion is not supported. true: The conversion is supported.

  • true
  • false
  • false

table.alter.add.index=false

  • table.create.comment.constraint

Whether to comment out redundant constraints. false (default value): The redundant constraints are not commented out.

  • true
  • false
  • false

table.create.comment.constraint=false

  • table.create.type.set

Whether to include the "check" constraint for the set type. false (default value): The constraint is not included.

  • true
  • false
  • false

table.create.type.set=false

  • table.create.type.enum

Whether to include the "in not null" constraint for the enum type. false (default value): The constraint is not included.

  • true
  • false
  • false

table.create.type.enum=false

  • table.create.columnCase

Whether to convert column fields to lowercase. true (default value): The column fields are converted to lowercase. false: The uppercase and lowercase letters are the same as those in the original SQL statement.

  • true
  • false
  • true

table.create.columnCase=true

  • table.option.colversion

Version of the column-store format. The value can be 1.0, 2.0 (default value), or 3.0.

  • 1.0
  • 2.0
  • 3.0
  • 2.0

table.option.colversion=2.0

  • table.origin.database.type

Source database type. The value can be bigquery, doris, synapse, or mysql&adb. The default value is mysql&adb.

  • bigquery
  • doris
  • synapse
  • mysql
  • adb
  • mysql&adb

table.origin.database.type = mysql

  • table.enable.hstore

Specifies whether to allow HStore tables. The value can be true or false. The default value is null. The value false indicates that hstore is set to false in the statement.

  • true
  • false
  • Null
  • null

table.enable.hstore=

  • table.enable.hstore.opt

Whether to allow the hstore_opt operation. true: The operation is allowed. false: The operation is not allowed.

  • true
  • false
  • true

table.enable.hstore.opt=true

  • table.partition.comment.enable

Whether to output the original SQL statement of the partition as a comment. The value can be true or false.

  • true
  • false
  • false

table.partition.comment.enable=false

  • table.type.schema.prefix

Whether to combine the type name with the schema name during type creation. The value can be true or false.

  • true
  • false
  • true

table.type.schema.prefix=true

  • table.option.partition.ttl

The partition_expiration_days parameter needs to be converted to an integer, so the rounding rule needs to be specified.

  • HALF_UP: The value is rounded off.
  • CEILING: The value is rounded up.
  • FLOOR: The value is rounded down.
  • HALF_UP
  • CEILING
  • FLOOR
  • HALF_UP

table.option.partition.ttl=HALF_UP