Skip to main content
GuideServerConfigure and deploy Tabsdata servers on your machine.TutorialsConfigure data integration workflows within a running Tabsdata server.API ReferenceCLI ReferenceRelease Notes
Version: 2.3.0

MySQLDest

class
class MySQLDest(
tables: MySQLTableNamesSpec,
if_table_exists: IfTableExistsSpec = 'append',
transactional: bool = True,
schema_evolution: SchemaEvolutionSpec = 'strict',
dest_cfg: DestCfgSpec | None = None,
)

Bases: Dest

Categories: destination

MySQL destination for @subscriber -- one target table per slot.

Parameters​

parameter

Target table names, qualified or bare (see MySQLTableNameSpec); one input slot per table, in order.

parameter
if_table_existsIfTableExistsSpec (Literal['append', 'replace'])

"append" (default) adds rows; "replace" truncates the table before inserting.

parameter
transactionalbool

When True (default), wrap every table write in one transactional session.

parameter
schema_evolutionSchemaEvolutionSpec (Literal['strict', 'update'])

What a write does when the batch's columns differ from the table's. "replace" makes the table the batch's own, so it is not affected. "strict" (the default) refuses a batch with a column the table lacks; "update" adds the column and widens a number column the batch has outgrown (a larger integer, double precision, a decimal that keeps every digit); other type differences are left to the database, where a value a column cannot hold fails the write. A column the batch lacks is written NULL either way.

parameter
dest_cfgDestCfgSpec | None (Mapping[Literal['mysql.logging_level', 'mysql.schema_evolution_engine', 'tabsdata.sql.write_engine', 'tabsdata.sql.chunk_size'], Any] | None)

Optional config mapping over the allowed keys only (mysql.logging_level, tabsdata.sql.write_engine, tabsdata.sql.chunk_size). mysql.schema_evolution_engine takes only "iceberg", the default.