# Microsoft Azure SQL

{% hint style="warning" %}
Best practice for production apps is to use REST as the data layer to access data and not directly integrate to SQL using the SQL data provider. The SQL data provider will be squiggled in blue to indicate it is not recommended, together with a message to use [REST](https://docs.jigx.com//building-apps-with-jigx/data/data-providers/rest) instead. See [REST endpoints from Azure SQL](https://docs.jigx.com/building-apps-with-jigx/data/data-providers/microsoft-azure-sql/rest-endpoints-from-azure-sql) for more information.
{% endhint %}

Integrating with an Azure SQL database is easy, using the SQL data provider in Jigx provides access to interact with external data efficiently. For more information on how the the provider functions, see [Microsoft Azure SQL](https://docs.jigx.com/building-apps-with-jigx/data/data-providers/microsoft-azure-sql).

## What is created

In this section, an SQL database is used to create a customer Jigx app that allows you to:

<table><thead><tr><th width="276.41796875">Functions &#x26; Jigs</th><th>Functionality description</th></tr></thead><tbody><tr><td><a href="/pages/3ZpSo780Nb2Ff5hPEB6y">List customers (SELECT)</a></td><td>View a list of customers.</td></tr><tr><td><a href="/pages/iDRIlRXAXeoFaElxenWu">List a single customer (SELECT)</a></td><td>View a single customer.</td></tr><tr><td><a href="/pages/gewM9sIs9XWxJpXOMF1w">Create a customer (INSERT)</a></td><td>Capture new customers in a form.</td></tr><tr><td><a href="/pages/SXJ6WOB4qP6VgZVgGAw3">Update a customer (UPDATE)</a></td><td>You can update customer details by tapping the Edit customer button. This populates a form with the customer's details and an update button.</td></tr></tbody></table>

## Before you begin

We have simplified the process by providing [database scripts](/examples/readme/data-providers/microsoft-azure-sql/database-scripts.md) to create the Customer SQL database on which the example is based.

## High-level steps

The SQL data provider is used in Jigx to integrate with an Azure SQL database. In this section, we follow these high-level steps:

1. Identify the SQL database to be used as your data source.
2. Configure SQL connection in Jigx Management.
3. Define a SQL call in a Jigx function in Jigx Builder.
4. Define data operations in the function, such as SELECT, INSERT, UPDATE, and DELETE. For each operation, create a new function to specify the operation.
5. Reference the Jigx functions in jigs.
6. Publish your solution
7. Test the data provider.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.jigx.com/examples/readme/data-providers/microsoft-azure-sql.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
