> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bondata.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Azure Synapse Analytics

> Connect BonData to Azure Synapse Analytics to sync your data warehouse tables

Azure Synapse Analytics is Microsoft's enterprise analytics service that brings together data warehousing and big data analytics. With BonData, you can connect directly to a Synapse dedicated SQL pool to read, enrich, and act on your warehouse data within Agent workflows.

## Database Connection

BonData connects to Azure Synapse Analytics over the TDS protocol using standard SQL authentication, the same way you would connect to a SQL Server database.

### Step 1: Locate Your SQL Endpoint

1. Open the [Azure Portal](https://portal.azure.com/) and go to your **Synapse workspace**
2. On the **Overview** page, find the **SQL endpoint** under **Dedicated SQL endpoint**
3. The endpoint has the format `<workspace-name>.sql.azuresynapse.net`

<Note>
  Connect to the **dedicated SQL pool** endpoint (`*.sql.azuresynapse.net`), not the serverless (`*-ondemand.sql.azuresynapse.net`) endpoint, unless you specifically intend to query serverless external tables.
</Note>

### Step 2: Configure Firewall Rules

1. In your Synapse workspace, go to **Networking** (or **Firewalls and virtual networks**)
2. Add BonData's IP addresses to the allowed IP range
3. Ensure **Allow Azure services and resources to access this workspace** is configured as required by your security policy
4. Save the changes

### Step 3: Create a SQL Login and User (Recommended)

For security, create a dedicated read-only user for BonData in your dedicated SQL pool:

```sql theme={null}
-- In the master database, create a login
CREATE LOGIN bondata_user WITH PASSWORD = 'your_secure_password';

-- In your dedicated SQL pool, create a user mapped to the login
CREATE USER bondata_user FOR LOGIN bondata_user;

-- Grant read access
EXEC sp_addrolemember 'db_datareader', 'bondata_user';
```

### Step 4: Gather Connection Details

Collect the following information:

* **Host**: Your workspace SQL endpoint (e.g., `myworkspace.sql.azuresynapse.net`)
* **Port**: `1433`
* **Database**: The name of your dedicated SQL pool
* **User**: The username created above
* **Password**: The password for the user

### Step 5: Connect in BonData

Enter your connection details in BonData to establish the connection.

## Required Fields

| Field    | Description                                                       |
| -------- | ----------------------------------------------------------------- |
| Host     | Workspace SQL endpoint (e.g., `<workspace>.sql.azuresynapse.net`) |
| Port     | Database server port (default: 1433)                              |
| Database | Name of the dedicated SQL pool                                    |
| User     | SQL authentication username                                       |
| Password | SQL authentication password                                       |

<Note>
  Azure Synapse requires encrypted connections. BonData connects using SQL authentication over an encrypted channel by default.
</Note>

## Available Data

Once connected, BonData can sync:

* **Tables** - All tables the user has SELECT access to
* **Views** - Database views accessible to the user
* **Custom Queries** - Run custom T-SQL queries to extract specific data
