SQL Server
Read every insert, update and delete from SQL Server change data capture as a typed event. Use it to trigger workflows, join in context and merge results back into your tables.
Database
Category
CDC
Sync mode
p95 900 ms
Latency
9 min
Setup time
What it can do
- Row insertedCDC
- Row updatedCDC
- Row deletedCDC
- Run a read queryRead
- Insert a rowWrite
- Update rowsWrite
- Merge by keyWrite
- Execute a stored procedureWrite
Overview
The SQL Server connector reads from the change tables that SQL Server maintains when change data capture is on. Workflows react to committed changes without triggers on your tables, and every event shows up in the trace of the run it started.
Teams use it to post journal entries to NetSuite when a ledger row lands, to keep Salesforce accounts in step with an ERP and to ask for approval in Microsoft Teams before a large credit note goes out.
Supported versions
SQL Server 2016 SP1 to 2022, Standard or Enterprise edition
Azure SQL Database, Azure SQL Managed Instance and Amazon RDS for SQL Server
Connections over TLS, with optional SSH tunnel or Azure Private Link
How CDC works
The SQL Server Agent capture job copies changes from the transaction log into change tables. Tessel reads those tables in log sequence order with cdc.fn_cdc_get_all_changes, checks each row against the schema and remembers the last LSN it delivered, so a restart picks up where it stopped.
Retention
The CDC cleanup job keeps three days of changes by default. If Tessel is paused for longer than that, it snapshots the affected tables again and marks the gap in the trace. Raise the retention with sys.sp_cdc_change_job if you pause connectors often.
Permissions needed
A db_owner turns on CDC once. After that, Tessel's login only needs read access and membership in the gating role named when each table was enabled. Write access is only required if a workflow writes back.
db_datareaderon the databaseMembership in the gating role, for example
tessel_cdcINSERT,UPDATEandEXECUTEonly where you write back
Six steps. About nine minutes.
Most of the time goes into enabling CDC on each table. Tessel confirms the capture job is running before you continue.
- Make sure SQL Server Agent is runningSQL Server1 min
- Enable CDC on the database and tablesSQL Server3 min
- Create a tessel login and add it to the gating roleSQL Server2 min
- Allow Tessel's static IPs for your regionNetwork1 min
- Paste the connection details and pick tablesTessel2 min
- Insert a test row and watch the event arriveVerify900 ms
Your change tables, put to work.
Connect SQL Server on the free plan. Up to three builders and 10,000 runs a month, no card required.