Table

User-defined data tables for storing and querying structured data

ta

Tables allow you to create and manage custom data tables directly within Sim. Store, query, and manipulate structured data within your workflows without needing external database integrations.

Why Use Tables?

  • No external setup: Create tables instantly without configuring external databases
  • Workflow-native: Data persists across workflow executions and is accessible from any workflow in your workspace
  • Flexible schema: Define columns with types (string, number, boolean, date, json) and constraints (required, unique)
  • Powerful querying: Filter, sort, and paginate data using MongoDB-style operators
  • Agent-friendly: Tables can be used as tools by AI agents for dynamic data storage and retrieval

Key Features:

  • Create tables with custom schemas
  • Insert, update, upsert, and delete rows
  • Query with filters and sorting
  • Batch operations for bulk inserts
  • Bulk updates and deletes by filter
  • Up to 10,000 rows per table, 100 tables per workspace

Creating Tables

Tables are created from the Tables section in the sidebar. Each table requires:

  • Name: Alphanumeric with underscores (e.g., customer_leads)
  • Description: Optional description of the table's purpose
  • Schema: Define columns with name, type, and optional constraints

Column Types

TypeDescriptionExample Values
stringText data"John Doe", "active"
numberNumeric data42, 99.99
booleanTrue/false valuestrue, false
dateDate/time values"2024-01-15T10:30:00Z"
jsonComplex nested data{"address": {"city": "NYC"}}

Column Constraints

  • Required: Column must have a value (cannot be null)
  • Unique: Values must be unique across all rows (enables upsert matching)

Usage Instructions

Create and manage custom data tables. Store, query, and manipulate structured data within workflows.

Tools

table_query_rows

Query rows from a table with filtering, sorting, and pagination

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID
filterobjectNoFilter conditions using MongoDB-style operators
sortobjectNoSort order as {column: "asc"|"desc"}
limitnumberNoMaximum rows to return (default: 100, max: 1000)
offsetnumberNoNumber of rows to skip (default: 0)

Output

ParameterTypeDescription
successbooleanWhether query succeeded
rowsarrayQuery result rows
rowCountnumberNumber of rows returned
totalCountnumberTotal rows matching filter
limitnumberLimit used in query
offsetnumberOffset used in query

table_insert_row

Insert a new row into a table

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID
dataobjectYesRow data as JSON object matching the table schema

Output

ParameterTypeDescription
successbooleanWhether row was inserted
rowobjectInserted row data including generated ID
messagestringStatus message

table_upsert_row

Insert or update a row based on unique column constraints. If a row with matching unique field exists, update it; otherwise insert a new row.

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID
dataobjectYesRow data to insert or update

Output

ParameterTypeDescription
successbooleanWhether row was upserted
rowobjectUpserted row data
operationstringOperation performed: "insert" or "update"
messagestringStatus message

table_batch_insert_rows

Insert multiple rows at once (up to 1000 rows per batch)

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID
rowsarrayYesArray of row data objects to insert

Output

ParameterTypeDescription
successbooleanWhether batch insert succeeded
rowsarrayArray of inserted rows with IDs
insertedCountnumberNumber of rows inserted
messagestringStatus message

table_update_row

Update a specific row by its ID

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID
rowIdstringYesRow ID to update
dataobjectYesData to update (partial update supported)

Output

ParameterTypeDescription
successbooleanWhether row was updated
rowobjectUpdated row data
messagestringStatus message

table_update_rows_by_filter

Update multiple rows matching a filter condition

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID
filterobjectYesFilter to match rows for update
dataobjectYesData to apply to matching rows
limitnumberNoMaximum rows to update (default: 1000)

Output

ParameterTypeDescription
successbooleanWhether update succeeded
updatedCountnumberNumber of rows updated
updatedRowIdsarrayIDs of updated rows
messagestringStatus message

table_delete_row

Delete a specific row by its ID

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID
rowIdstringYesRow ID to delete

Output

ParameterTypeDescription
successbooleanWhether row was deleted
deletedCountnumberNumber of rows deleted (1 or 0)
messagestringStatus message

table_delete_rows_by_filter

Delete multiple rows matching a filter condition

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID
filterobjectYesFilter to match rows for deletion
limitnumberNoMaximum rows to delete (default: 1000)

Output

ParameterTypeDescription
successbooleanWhether delete succeeded
deletedCountnumberNumber of rows deleted
deletedRowIdsarrayIDs of deleted rows
messagestringStatus message

table_get_row

Get a single row by its ID

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID
rowIdstringYesRow ID to retrieve

Output

ParameterTypeDescription
successbooleanWhether row was found
rowobjectRow data
messagestringStatus message

table_get_schema

Get the schema definition for a table

Input

ParameterTypeRequiredDescription
tableIdstringYesTable ID

Output

ParameterTypeDescription
successbooleanWhether schema was retrieved
namestringTable name
columnsarrayArray of column definitions
messagestringStatus message

Filter Operators

Filters use MongoDB-style operators for flexible querying:

OperatorDescriptionExample
$eqEquals{"status": {"$eq": "active"}} or {"status": "active"}
$neNot equals{"status": {"$ne": "deleted"}}
$gtGreater than{"age": {"$gt": 18}}
$gteGreater than or equal{"score": {"$gte": 80}}
$ltLess than{"price": {"$lt": 100}}
$lteLess than or equal{"quantity": {"$lte": 10}}
$inIn array{"status": {"$in": ["active", "pending"]}}
$ninNot in array{"type": {"$nin": ["spam", "blocked"]}}
$containsString contains{"email": {"$contains": "@gmail.com"}}

Combining Filters

Multiple field conditions are combined with AND logic:

{
  "status": "active",
  "age": {"$gte": 18}
}

Use $or for OR logic:

{
  "$or": [
    {"status": "active"},
    {"status": "pending"}
  ]
}

Sort Specification

Specify sort order with column names and direction:

{
  "createdAt": "desc"
}

Multi-column sorting:

{
  "priority": "desc",
  "name": "asc"
}

Built-in Columns

Every row automatically includes:

ColumnTypeDescription
idstringUnique row identifier
createdAtdateWhen the row was created
updatedAtdateWhen the row was last modified

These can be used in filters and sorting.

Limits

ResourceLimit
Tables per workspace100
Rows per table10,000
Columns per table50
Max row size100KB
String value length10,000 characters
Query limit1,000 rows
Batch insert size1,000 rows
Bulk update/delete1,000 rows

Notes

  • Category: blocks
  • Type: table
  • Tables are scoped to workspaces and accessible from any workflow within that workspace
  • Data persists across workflow executions
  • Use unique constraints to enable upsert functionality
  • The visual filter/sort builder provides an easy way to construct queries without writing JSON

On this page

Start building today
Trusted by over 60,000 builders.
Build Agentic workflows visually on a drag-and-drop canvas or with natural language.
Get started