MySQL Beta
Fivetran supports MySQL database as a destination.
NOTE: Fivetran supports MySQL as both a database connector and a destination.
MySQL is not typically used as a data warehouse because it is a row-based database more suited to transactional use-cases. Large analytical querying is much faster on columnar warehouses.
WARNING: MySQL database can fail to perform basic queries for even medium volumes of data and is not appropriate as a data warehouse. We support MySQL database as a test environment. If you run into these limitations, you will need to migrate to a supported destination.
Supported implementations
Fivetran supports connecting with five different MySQL implementations:
Type transformation mapping
The data types in your MySQL database follow Fivetran's standard data type storage.
We use the following data type conversions:
Fivetran Data Type | Destination Data Type | Notes |
---|---|---|
BOOLEAN | BOOLEAN | |
SHORT | SMALLINT | |
INT | INTEGER | |
LONG | BIGINT | |
BIGDECIMAL | DECIMAL | |
FLOAT | REAL | |
DOUBLE | DOUBLEPRECISION | |
LOCALDATE | DATE | |
LOCALDATETIME | DATETIME | |
INSTANT | TIMESTAMP | For MySQL version 5.7 or later, we convert INSTANT to TIMESTAMP(6). MySQL's TIMESTAMP data type range begins with 1970-01-01 00:00:01.000000 and ends with 2038-01-19 03:14:07.999999 . We convert an epoch TIMESTAMP of 1970-01-01 00:00:00 to 1970-01-01 00:00:01 because there are often primary keys with this value. We convert an epoch TIMESTAMP beyond 2038-01-19 03:14:07.999999 to null because primary keys rarely have such values and futuristic dates capped at 2038 can be misleading. |
STRING | LONGTEXT or VARCHAR(b) | We convert STRING:
|
JSON | JSON | For versions prior to MySQL version 5.7.8, we convert JSON to TEXT because previous versions don't support JSON. |
BINARY | LONGBLOB or VARBINARY(b) | We convert BINARY:
|
IMPORTANT: MySQL databases with versions less than 5.7 don’t support fractional timestamps. Fivetran skips source tables from a sync if a table has a TIMESTAMP primary key column or if you activated history mode for the table.
Setup guide
Follow our step-by-step setup guides for specific instructions on how to set up your MySQL database as a destination:
Primary key creation
Fivetran creates primary keys for a MySQL database in either of the following scenarios:
MySQL version earlier than 5.7.7, or MariaDB version earlier than 10.2:
- If the total number of primary keys provided by the source is less than 16, and the sum of the byte length of String primary keys is less than 191.
MySQL version 5.7.7 and later, or MariaDB version 10.2 and later:
- If the total number of primary keys provided by the source is less than 16, and the sum of the byte length of String primary keys is less than 768.
Data load costs
Whether you are self-hosting MySQL or using a managed service, you will not be charged extra when we load data into your database.