Data Manipulation Language (DML) statements are used to insert, update, and delete data in tables. Spice supports DML operations on write-capable data connectors (opens in a new tab) configured with access: read_write.
:::warning[Supported Operations]
Spice supports INSERT for write-capable connectors and MERGE INTO for Spice Cayenne (opens in a new tab) catalog tables. UPDATE and DELETE statements are not yet supported as standalone operations. For data modifications, use MERGE INTO or the source database directly.
:::
:::info Spice is built on Apache DataFusion (opens in a new tab) and uses the PostgreSQL dialect, even when querying datasources with different SQL dialects. :::
Insert new rows into a table.
table_name: The name of the target tablecolumn_name: Optional list of column names to insert into. If omitted, values must be provided for all columns in table orderexpression: Values to insert into the corresponding columnsquery: A SELECT statement to insert results from another table or query