> For the complete documentation index, see [llms.txt](https://docs.bdb.ai/data-pipeline/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.bdb.ai/data-pipeline/getting-started/homepage/create-job/task-components/readers/azure-blob-reader.md).

# Azure Blob Reader

This task is used to read data from Azure blob container.

### Configuring the Meta Information tab fields <a href="#configuring-the-over-all-meta-information-tab-fields" id="configuring-the-over-all-meta-information-tab-fields"></a>

<figure><img src="https://363587200-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fuq3RSHHup7fjHYaspk7y%2Fuploads%2FGCATLTAuUJDqsY01lRSh%2Fimage.png?alt=media&amp;token=283bbe2b-d956-4744-989f-1ba3a0dc1522" alt=""><figcaption></figcaption></figure>

* **Read using:** There are three(3) options available under this tab:
  1. **Shared Access Signature:**
  2. **Secret Key**
  3. **Principal Secret**&#x20;

## Read using **Shared Access Signature:**

**Provide the following details:**

1. **Shared Access Signature:** This is a URI that grants restricted access rights to Azure Storage resources.
2. **Account Name:** Provide the Azure account name.
3. **Container:** Provide the container name from where the file is located and which has to be read.
4. **File type:** There are four(5) types of file extensions are available under it:
   * ***CSV:*** The ***Header*** and ***Infer Schema*** fields get displayed with ***CSV*** as the selected File Type. Enable ***Header*** option to get the Header of the reading file and enable Infer Schema option to get true schema of the column in the CSV file.  &#x20;
   * ***JSON***: The **Multiline** and **Charset** fields get displayed with ***JSON*** as the selected File Type. Check-in the **Multiline** option if there is any multiline string in the file.
   * ***PARQUET***: No extra field gets displayed with PARQUET as the selected File Type.
   * ***AVRO***: This File Type provides two drop-down menus.
     * ***Compression***: Select an option out of the ***Deflate*** and ***Snappy*** options.
     * ***Compression Level***: This field appears for the Deflate compression option. It provides **0** to **9** levels via a drop-down menu.
   * ***XML:*** Select this option to read XML file. If this option is selected, the following fields will get displayed:
     * **Infer schema:** Enable this option to get true schema of the column.
     * **Path:** Provide the path of the file.
     * **Root Tag:** Provide the root tag from the XML files.
     * **Row Tags:** Provide the row tags from the XML files.
     * **Join Row Tags:** Enable this option to join multiple row tags.
5. **Path:** This option will appear once the file type is selected. Enter the path where the selected file type is located.
6. **Read Directory:** Check in this box to read the specified directory.&#x20;
7. **Query:** Provide Spark SQL query in this field.

## Read using Secret Key Option:

Provide the following details:

<figure><img src="https://363587200-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fuq3RSHHup7fjHYaspk7y%2Fuploads%2F4QntmYCeYQAvwctEqEG4%2Fimage.png?alt=media&amp;token=d983e5ab-f187-49ce-9428-2ccc388bec7f" alt=""><figcaption><p>Read using secret key</p></figcaption></figure>

* **Account Key:** Enter the Azure account key. In Azure, an account key is a security credential that is used to authenticate access to storage resources, such as blobs, files, queues, or tables, in an Azure storage account.
* **Account Name:** Provide the Azure account name.
* **Container:** Provide the container name from where the blob is located.\
  A container is a logical unit of storage in Azure Blob Storage that can hold blobs. It is similar to a directory or folder in a file system, and it can be used to organize and manage blobs.
* **File type:** There are four(5) types of file extensions are available under it:
  * ***CSV:*** The ***Header*** and ***Infer Schema*** fields get displayed with ***CSV*** as the selected File Type. Enable ***Header*** option to get the Header of the reading file and enable Infer Schema option to get true schema of the column in the CSV file.  &#x20;
  * ***JSON***: The **Multiline** and **Charset** fields get displayed with ***JSON*** as the selected File Type. Check-in the **Multiline** option if there is any multiline string in the file.
  * ***PARQUET***: No extra field gets displayed with PARQUET as the selected File Type.
  * ***AVRO***: This File Type provides two drop-down menus.
    * ***Compression***: Select an option out of the ***Deflate*** and ***Snappy*** options.
    * ***Compression Level***: This field appears for the Deflate compression option. It provides **0** to **9** levels via a drop-down menu.
  * ***XML:*** Select this option to read XML file. If this option is selected, the following fields will get displayed:
    * **Infer schema:** Enable this option to get true schema of the column.
    * **Path:** Provide the path of the file.
    * **Root Tag:** Provide the root tag from the XML files.
    * **Row Tags:** Provide the row tags from the XML files.
    * **Join Row Tags:** Enable this option to join multiple row tags.
* **Path:** This option will appear once the file type is selected. Enter the path where the selected file type is located.
* **Read Directory:** Check in this box to read the specified directory.&#x20;
* **Query:** Provide Spark SQL query in this field.

## Read using Principal Secret:

<figure><img src="https://363587200-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fuq3RSHHup7fjHYaspk7y%2Fuploads%2FBwQF7m3ICq2uOL2nVACW%2Fimage.png?alt=media&amp;token=248b06e3-769f-4aff-85f0-40e1659cf0cd" alt=""><figcaption><p>Reading using principal secret</p></figcaption></figure>

**Provide the following details:**

* **Client ID:** Provide Azure Client ID.\
  The client ID is the unique Application (client) ID assigned to your app by Azure AD when the app was registered.
* **Tenant ID:** Provide the Azure Tenant ID.\
  Tenant ID (also known as Directory ID) is a unique identifier that is assigned to an Azure AD tenant, which represents an organization or a developer account. It is used to identify the organization or developer account that the application is associated with.
* **Client Secret:** Enter the Azure Client Secret.\
  Client Secret (also known as Application Secret or App Secret) is a secure password or key that is used to authenticate an application to Azure AD.
* **Account Name:** Provide the Azure account name.
* **Container:** Provide the container name from where the blob is located.\
  A container is a logical unit of storage in Azure Blob Storage that can hold blobs. It is similar to a directory or folder in a file system, and it can be used to organize and manage blobs.
* **Query:** Provide Spark SQL query in this field.
* **File type:** There are four(5) types of file extensions are available under it:
  * ***CSV:*** The ***Header*** and ***Infer Schema*** fields get displayed with ***CSV*** as the selected File Type. Enable ***Header*** option to get the Header of the reading file and enable Infer Schema option to get true schema of the column in the CSV file.  &#x20;
  * ***JSON***: The **Multiline** and **Charset** fields get displayed with ***JSON*** as the selected File Type. Check-in the **Multiline** option if there is any multiline string in the file.
  * ***PARQUET***: No extra field gets displayed with PARQUET as the selected File Type.
  * ***AVRO***: This File Type provides two drop-down menus.
    * ***Compression***: Select an option out of the ***Deflate*** and ***Snappy*** options.
    * ***Compression Level***: This field appears for the Deflate compression option. It provides **0** to **9** levels via a drop-down menu.
  * ***XML:*** Select this option to read XML file. If this option is selected, the following fields will get displayed:
    * **Infer schema:** Enable this option to get true schema of the column.
    * **Path:** Provide the path of the file.
    * **Root Tag:** Provide the root tag from the XML files.
    * **Row Tags:** Provide the row tags from the XML files.
    * **Join Row Tags:** Enable this option to join multiple row tags.
