# MSSQL

1\. Go to **Workflows** and click **Create Workflow** (Before creating a new workflow, you have to [create a resource](https://docs.acho.io/acho-studio/resources/add-a-resource) first and then [import the resource to a project](https://docs.acho.io/acho-studio/data-prep-projects/create-a-project)).

<figure><img src="https://3574406564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MB_fx7PCUqvFEdrucJC%2Fuploads%2FbJYfOQukxnoVgYEW1e5p%2Fimage.png?alt=media&#x26;token=dbd838d7-dca5-49bd-9e01-eae717d39685" alt=""><figcaption></figcaption></figure>

2\. In Workflow, drag **MSSQL** from the right sidebar to the canvas.&#x20;

<figure><img src="https://3574406564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MB_fx7PCUqvFEdrucJC%2Fuploads%2F3Cl0k0guJ6YpVrpYaFnf%2Fimage.png?alt=media&#x26;token=9e592349-a01d-4dcb-8e81-49326809d85f" alt=""><figcaption></figcaption></figure>

3\. Configure your MSSQL destination. (Remember to white list Acho's IP address: **`35.239.14.244`**)

* Host
* Port
* Database
* Schema
* Username
* Password

![](https://3574406564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MB_fx7PCUqvFEdrucJC%2Fuploads%2F9vATRlTdb6l5hG16Hacc%2Fimage.png?alt=media\&token=f0bcd315-5fd5-4fdd-a12f-09c4df9db419)

4\. Once your MSSQL is set up successfully, the status will become <img src="https://3574406564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MB_fx7PCUqvFEdrucJC%2Fuploads%2F7JqWiCfMaYZbaILX15Er%2Fimage.png?alt=media&#x26;token=15359abc-254d-4fc7-9623-fbd4bb426e97" alt="" data-size="line"> . Your MSSQL database will be stored in **Existing Database**, so next time you can drag it to the Workflow directly without filling out credentials.&#x20;

<figure><img src="https://3574406564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MB_fx7PCUqvFEdrucJC%2Fuploads%2FHijLsqJSUawKvjjvaYjN%2Fimage.png?alt=media&#x26;token=ccb26ae5-d0b8-418e-843b-859d8d7e6c86" alt=""><figcaption></figcaption></figure>

5\. Connect the table to your MSSQL database.

<figure><img src="https://3574406564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MB_fx7PCUqvFEdrucJC%2Fuploads%2F3gTmnqr0vCMgpeEQdW2t%2Fimage.png?alt=media&#x26;token=497bd913-10f7-4c0a-87cf-bad3ec987a3f" alt=""><figcaption></figcaption></figure>

6\. Choose the **replication method** and click **Save.** When you export data to MSSQL, Acho will create a new table in your MSSQL. When your project table is updated, your table in MSSQL will be updated as well. The replication method is to determine how to update your table in MSSQL.

* **Full Refresh:** Replace your MSSQL table with the new table.

<figure><img src="https://3574406564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MB_fx7PCUqvFEdrucJC%2Fuploads%2FVeUqntnRXRRpXXtkWVJc%2Fimage.png?alt=media&#x26;token=e265898b-35ab-495e-a990-07464370234c" alt=""><figcaption></figcaption></figure>

7\. You can set up the **Data Sync** for your project table. Once your project table is updated, new data will be exported to your database automatically.&#x20;

<figure><img src="https://3574406564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MB_fx7PCUqvFEdrucJC%2Fuploads%2FOthFG5CG2PTUQQcT0Whu%2Fimage.png?alt=media&#x26;token=21f8bd0e-22e9-4480-81ac-f91983f5aaf8" alt=""><figcaption></figcaption></figure>
