> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify-poc.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# disable_chunk_skipping()

> Disable range tracking for columns of chunks from a hypertable

export const TIMESCALE_DB = 'TimescaleDB';

export const HYPERTABLE_CAP = 'Hypertable';

export const HYPERTABLE = 'hypertable';

export const COLUMNSTORE = 'columnstore';

export const CHUNK_CAP = 'Chunk';

export const CHUNK = 'chunk';

<Icon icon="flask" /> Early access <Icon icon="tag" iconType="duotone" /> Since [2.16.0][tsdb-2.16.0]

Disable range tracking for a specific column in a {HYPERTABLE} **in the {COLUMNSTORE}**.

## Samples

In this sample, you convert the `conditions` table to a {HYPERTABLE} with
partitioning on the `time` column. You then specify and enable additional
columns to track ranges for. You then disable range tracking:

```sql theme={"dark"}
SELECT create_hypertable('conditions', 'time');
SELECT enable_chunk_skipping('conditions', 'device_id');
SELECT disable_chunk_skipping('conditions', 'device_id');
```

<Note>
  Best practice is to enable range tracking on columns which are correlated to the
  partitioning column. In other words, enable tracking on secondary columns that are
  referenced in the `WHERE` clauses in your queries.
  Use this API to disable range tracking on columns when the query patterns don't
  use this secondary column anymore.
</Note>

## Arguments

The syntax is:

```sql theme={"dark"}
SELECT disable_chunk_skipping(
    hypertable = '<hypertable_name>',
    column_name = '<column_name>',
    if_not_exists = true | false
);
```

| Name            | Type     | Default | Required | Description                                                                                                           |
| --------------- | -------- | ------- | -------- | --------------------------------------------------------------------------------------------------------------------- |
| `hypertable`    | REGCLASS | -       | ✔        | Hypertable that the column belongs to                                                                                 |
| `column_name`   | NAME     | -       | ✔        | Column to disable tracking range statistics for                                                                       |
| `if_not_exists` | BOOLEAN  | `FALSE` | ✖        | Set to `true` so that a notice is sent when ranges are not being tracked for a column. By default, an error is thrown |

## Returns

| Column          | Type    | Description                                                                                                    |
| --------------- | ------- | -------------------------------------------------------------------------------------------------------------- |
| `hypertable_id` | INTEGER | ID of the {HYPERTABLE} in {TIMESCALE_DB}.                                                                      |
| `column_name`   | NAME    | Name of the column range tracking is disabled for                                                              |
| `disabled`      | BOOLEAN | Returns `true` when tracking is disabled. `false` when `if_not_exists` is `true` and the entry was not removed |

<Note>
  To `disable_chunk_skipping()`, you must have first called [enable\_chunk\_skipping][enable_chunk_skipping]
  and enabled range tracking on a column in the hypertable.
</Note>

[enable_chunk_skipping]: /api-reference/timescaledb/hypertables/enable_chunk_skipping

[tsdb-2.16.0]: https://github.com/timescale/timescaledb/releases/tag/2.16.0
