# Export To SQL Server (Stored Proc)

> Send Datahub data to SQL Server by calling a stored procedure.

The Export To SQL Server (Stored Proc) node exports dataflow data to a Microsoft SQL Server database by executing a stored procedure.

This node can be used to:

- Insert or update data
- Execute SQL business logic
- Synchronize dataflow data with external databases

## Configuration

| Property | Description |
| --- | --- |
| Connection | The SQL Server connection to use. |
| Advanced | Opens the connection configuration window. |
| Time-out | Maximum execution time in seconds before the node stops execution. |
| Log Info Messages | Enables SQL informational logging. |
| Output Parameters | Defines how output parameters are returned. Options: None, Mapped Columns, New Columns. |

### Connection configuration

| Setting | Description |
| --- | --- |
| Name | Name of the connection. |
| Connection type | Database type being used. |
| Connection string | SQL Server connection string. |
| Connection timeout | Connection timeout duration in seconds. |

Example connection string:

```
Server=myServerAddress;
Database=myDataBase;
User Id=myUsername;
Password=myPassword;
Encrypt=True;
TrustServerCertificate=True;
```

Use the Validate button to test the connection before saving.

## When to use it

Use this node when SQL Server should receive data through controlled database logic instead of direct table writes.

## Tips

- Check that the stored procedure parameters match the dataflow output.
- Use clear error handling for database connection or validation failures.