[Yandex Cloud documentation](../../index.md) > [Yandex Query](../index.md) > Data sources and sinks > Working with Yandex Object Storage > Reading data via bindings

# Reading data from Object Storage via Query data bindings

When you need to run the same queries repeatedly, you can use bindings to avoid specifying all query details each time.

Query example for reading data via a binding:

```sql
SELECT
    *
FROM
    `logs`
WHERE
    version>1
```

## Setting up a data binding {#binding-settings}

To create a binding to read data from Object Storage:

1. In the [management console](https://console.yandex.cloud), select the folder where you want to create a binding.
1. Navigate to **Yandex Query**.
1. In the left-hand panel, switch to the **Bindings** tab.
1. Click ![info](../../_assets/console-icons/plus.svg) **Create**.
1. Under **Connection parameters**:

   1. In the **Type** field, select `Object Storage`.
   1. In the **Connection** field, select an existing connection or [create a new one](object-storage.md#create_connection).

1. Under **Binding parameters**:

   1. In the **Name** field, specify the binding name.
   1. In the **Path** field, specify the [path to bucket data](object-storage.md#path_format). You can specify parts of file names using `/*`, e.g., `yellow/*.csv`.
   1. In the **Compression** field, specify the [data compression](formats.md#compression) method.
   1. In the **Format** field, specify the [data storage format](formats.md#formats).
   1. Select a partitioning mode and specify the list of [partition columns](../concepts/partitioning.md) with their types.

      For the **Extended** mode, specify the [partition projection](../concepts/partition-projection.md) columns.
   1. Specify the data columns and their types.
   
      Alternatively, you can click **Detect columns** to do this automatically.

1. To validate the data, click **Preview**.
1. Click **Create**.

## Data model {#data-model}

Object Storage stores data as binary files. To read data, use the following SQL statement:

```sql
SELECT
    <expression>
FROM
    `<binding>`
WHERE
    <filter>;
```

Where:

* `<binding>`: Name of the data binding you created earlier.

## Example of reading data via bindings {#binding-example}

Query example for reading Object Storage data via bindings:

```sql
SELECT
    *
FROM
    `binding_name`
```

Where `binding_name` is the Object Storage data binding name.