Insert Rows
AI-generatedSummary
Insert new rows into a specified database table in CloudBeaver using a shared project connection.
Inputs
- Connection ID (required) — The ID of the database connection in CloudBeaver, obtained by opening the database in the Database Navigator and checking the ID.
- Default Database — Optional database or catalog to use when executing the SQL insert. Leave empty to use the connection's default database.
- Database Type — Type of the database (PostgreSQL, MySQL, SQL Server) which affects identifier quoting style. Defaults to PostgreSQL.
- Schema — Optional database schema that contains the table. Leave empty to omit schema prefix.
- Table (required) — Name of the table into which rows will be inserted.
- Columns (required) — A list of columns and their corresponding values and types to insert. Value types can be Boolean, Null, Number, Raw SQL, or String; careful use of Raw SQL is recommended for trusted expressions (e.g., NOW()).
- Options — Additional options such as query timeout in seconds.
Output shape
a list of objects each indicating success or error for each inserted row, paired by input item index
Each input item corresponds to one insertion attempt; output includes { success: true } for success or { error: 'message' } for failure. Query timeout defaults to 60 seconds if unspecified. Only connections from the Shared project are supported.
Examples
Example 1: Insert a new user row into the 'users' table in the 'public' schema of a PostgreSQL database, providing column 'name' with value 'Alice' and 'age' with the number 30.
Set 'Connection ID' with the CloudBeaver connection ID, optionally specify 'Default Database' if different from connection default, 'Database Type' as 'PostgreSQL', 'Schema' as 'public', 'Table' as 'users', and add two columns with their values and types (e.g. 'name' - 'Alice' - 'string', 'age' - '30' - 'number').