---
title: Table properties reference
description: Reference for Delta Lake and Apache Iceberg table properties on Databricks. Covers data skipping, file size tuning, deletion vectors, compaction, change data feed, and isolation levels.
canonical_url: https://docs.databricks.com/gcp/en/tables/table-properties
---

# Table properties reference

Delta Lake and Apache Iceberg tables use table properties to configure behavior and features, including data layout, file size, data skipping, isolation level, and change data feed.

> [!NOTE]
>
> All operations that set or update table properties conflict with other concurrent write operations, causing them to fail. Databricks recommends you modify a table property only when there are no concurrent write operations on the table.

## <a id="modify-properties" />Modify table properties

To modify table properties of existing tables, use [SET TBLPROPERTIES](https://docs.databricks.com/gcp/en/sql/language-manual/sql-ref-syntax-ddl-tblproperties.md).

## <a id="format-prefixes" />Delta and Iceberg property prefixes

Delta Lake and Apache Iceberg tables share the same table property names, but require different prefixes:

* **Delta Lake tables**: Use the `delta.` prefix
* **Iceberg tables**: Use the `iceberg.` prefix

For example, to enable deletion vectors on a table:

### Delta Lake

```sql
ALTER TABLE <table-name> SET TBLPROPERTIES ('delta.enableDeletionVectors' = true);
```

### Iceberg

```sql
ALTER TABLE <table-name> SET TBLPROPERTIES ('iceberg.enableDeletionVectors' = true);
```

## <a id="property-interaction" />Table properties and `SparkSession` properties

Each table has its own table properties that control its behavior. Some `SparkSession` configurations always override table properties. For example, `autoCompact.enabled` and `optimizeWrite.enabled` enable auto compaction and optimized writes at the `SparkSession` level. Databricks recommends using table-scoped configurations for most workloads.

You can set default values for new tables using `SparkSession` configurations. These defaults only apply to new tables and don't affect existing table properties. `SparkSession` configurations use a different prefix than table properties, as shown in the following table:

| Table property                       | `SparkSession` configuration                                                                                   |
| ------------------------------------ | -------------------------------------------------------------------------------------------------------------- |
| `delta.<conf>`<br />`iceberg.<conf>` | `spark.databricks.delta.properties.defaults.<conf>`<br />`spark.databricks.iceberg.properties.defaults.<conf>` |

For example, to set the `appendOnly = true` property for all new tables created in a session, set the following:

### Delta Lake

```sql
SET spark.databricks.delta.properties.defaults.appendOnly = true
```

### Iceberg

```sql
SET spark.databricks.iceberg.properties.defaults.appendOnly = true
```

## <a id="properties" />Table properties

Most of the following table properties are available for both Delta Lake and Apache Iceberg tables, except where indicated. Use the `delta.` prefix for Delta Lake tables and `iceberg.` prefix for Iceberg tables.

| Property                                                        | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| --------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `appendOnly`                                                    | `true` to make the table append-only. Append-only tables don't allow deleting existing records or updating existing values.<br />Data type: `Boolean`<br />Default: `false`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| `autoOptimize.autoCompact`                                      | Automatically combines small files within table partitions to reduce small file problems. Accepts `auto` (recommended), `true`, `legacy`, or `false`.<br />See [Auto compaction](https://docs.databricks.com/gcp/en/tables/tune-file-size.md#auto-compact).<br />Data type: `String`<br />Default: (none)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| `autoOptimize.optimizeWrite`                                    | `true` to automatically optimize the layout of the files for this table during writes.<br />See [Optimized writes](https://docs.databricks.com/gcp/en/tables/tune-file-size.md#optimized-writes).<br />Data type: `Boolean`<br />Default: (none)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| `checkpoint.writeStatsAsJson`                                   | `true` to write file statistics in checkpoints in JSON format for the `stats` column.<br />Data type: `Boolean`<br />Default: `false`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| `checkpoint.writeStatsAsStruct`                                 | `true` to write file statistics to checkpoints in struct format for the `stats_parsed` column and to write partition values as a struct for `partitionValues_parsed`.<br />Data type: `Boolean`<br />Default: `true`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| `checkpointPolicy`                                              | `classic` for classic checkpoints. `v2` for v2 checkpoints.<br />See [Checkpoint V2](https://docs.databricks.com/gcp/en/tables/features/checkpoint-v2.md) and [Compatibility for tables with liquid clustering](https://docs.databricks.com/gcp/en/tables/clustering.md#compatibility).<br />Data type: `String`<br />Default: `classic`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `columnMapping.mode`                                            | Enables column mapping for table columns and the corresponding Parquet columns that use different names. Valid values are `none`, `name`, and `id`.<br />See [Rename and drop columns with Delta Lake column mapping](https://docs.databricks.com/gcp/en/tables/features/column-mapping.md).<br />Note: Enabling `columnMapping.mode` automatically enables `randomizeFilePrefixes`.<br />Data type: `DeltaColumnMappingMode`<br />Default: `none`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `compatibility.symlinkFormatManifest.enabled` (Delta Lake only) | `true` to configure the Delta Lake table so that all write operations on the table automatically update the manifests.<br />Data type: `Boolean`<br />Default: `false`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| `dataSkippingNumIndexedCols`                                    | The number of columns to collect statistics about for data skipping. A value of `-1` means to collect statistics for all columns.<br />See [Data skipping](https://docs.databricks.com/gcp/en/tables/data-skipping.md).<br />Data type: `Int`<br />Default: `32`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| `dataSkippingStatsColumns`                                      | A comma-separated list of column names on which to collect statistics to enhance data skipping functionality. This property takes precedence over `dataSkippingNumIndexedCols`.<br />See [Data skipping](https://docs.databricks.com/gcp/en/tables/data-skipping.md).<br />Data type: `String`<br />Default: (none)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| `deletedFileRetentionDuration`                                  | The shortest duration to keep logically deleted data files before deleting them physically. This prevents failures in stale readers after compactions or partition overwrites.<br />Databricks recommends the default value of 7 days or higher. If your retention period is too short, long-running jobs might have their uncommitted files deleted before the job completes.<br />See [Configure data retention for time travel queries](https://docs.databricks.com/gcp/en/tables/history.md#data-retention).<br />Data type: `CalendarInterval`<br />Default: `interval 1 week`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| `enableChangeDataFeed`                                          | `true` to enable change data feed.<br />See [Use change data feed](https://docs.databricks.com/gcp/en/tables/features/change-data-feed.md#enable).<br />Data type: `Boolean`<br />Default: `false`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `enableColumnUpdates-preview` (Delta Lake only)                 | Set to `true` to enable Efficient Column Updates (Beta). Reads and writes require Databricks Runtime 19 or above. The table must also use catalog commits, row tracking, deletion vectors, and column mapping in `id` mode.<br />See [Efficient column updates in Delta Lake](https://docs.databricks.com/gcp/en/tables/features/efficient-column-updates.md).<br />Data type: `Boolean`<br />Default: `false`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| `enableDeletionVectors`                                         | `true` to enable deletion vectors and predictive I/O for updates.<br />See [Deletion vectors in Databricks](https://docs.databricks.com/gcp/en/tables/features/deletion-vectors.md) and [Enable deletion vectors](https://docs.databricks.com/gcp/en/iceberg/iceberg-v3.md#deletion-vectors).<br />Data type: `Boolean`<br />Default: Depends on workspace admin settings and Databricks Runtime version. See [Auto-enable deletion vectors](https://docs.databricks.com/gcp/en/admin/workspace-settings/deletion-vectors.md).                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| `enableIcebergCompatV2` (Delta Lake only)                       | `true` to enable IcebergCompatV2, which writes data in a format compatible with Iceberg readers. To enable Iceberg reads, set this property together with `universalFormat.enabledFormats`.<br />See [Read Delta Lake tables with Iceberg clients](https://docs.databricks.com/gcp/en/delta/iceberg-reads.md).<br />Data type: `Boolean`<br />Default: (none)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| `enableRowTracking` (Delta Lake only)                           | `true` to enable row tracking, which assigns stable row IDs and row commit versions to each row for row-level lineage. Available in Databricks Runtime 14.0 and above. Apache Iceberg v3 tables include row tracking automatically.<br />See [Row tracking in Databricks](https://docs.databricks.com/gcp/en/tables/features/row-tracking.md).<br />Data type: `Boolean`<br />Default: `false`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| `enableTypeWidening`                                            | `true` to enable type widening.<br />See [Type widening](https://docs.databricks.com/gcp/en/tables/features/type-widening.md).<br />Data type: `Boolean`<br />Default: `false`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| `format-version` (Apache Iceberg managed tables only)           | The Iceberg table format version.<br />To create an Iceberg v3 table, set this property to `3` when you create the table, from Databricks or from an external Iceberg engine. To upgrade an existing table to v3, set this property from Databricks. Don't change this property on an existing table from an external engine.<br />See [Create and use managed tables with Apache Iceberg v3](https://docs.databricks.com/gcp/en/iceberg/iceberg-v3.md).<br />Data type: `Int`<br />Default: `2`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| `isolationLevel`                                                | The degree to which a transaction must be isolated from modifications made by concurrent transactions.<br />Valid values are `Serializable` and `WriteSerializable`.<br />See [Isolation levels (WriteSerializable and Serializable)](https://docs.databricks.com/gcp/en/optimizations/isolation/isolation-levels.md).<br />Data type: `String`<br />Default: `WriteSerializable`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| `logRetentionDuration`                                          | How long to keep the history for a table.<br />Databricks automatically cleans up log entries older than the retention interval each time a checkpoint is written. Setting this property to a large value retains many log entries. This doesn't impact performance because operations against the log are constant time. Operations on history are parallel but become more expensive as the log size increases.<br />See [Configure data retention for time travel queries](https://docs.databricks.com/gcp/en/tables/history.md#data-retention).<br />Data type: `CalendarInterval`<br />Default: `interval 30 days`                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| `minReaderVersion` (Delta Lake only)                            | The minimum required protocol reader version to read from this table.<br />Databricks recommends against manually configuring this property.<br />See [Delta Lake feature compatibility and protocols](https://docs.databricks.com/gcp/en/tables/features/feature-compatibility.md).<br />Data type: `Int`<br />Default: `1`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| `minWriterVersion` (Delta Lake only)                            | The minimum required protocol writer version to write to this table.<br />Databricks recommends against manually configuring this property.<br />See [Delta Lake feature compatibility and protocols](https://docs.databricks.com/gcp/en/tables/features/feature-compatibility.md).<br />Data type: `Int`<br />Default: `2`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| `parquet.compression.codec`                                     | The compression codec for a table.<br />Valid values: `ZSTD`, `SNAPPY`, `GZIP`, `LZ4`, `BROTLI` (support varies by format)<br />Available in Databricks Runtime 16.0 and above, setting this property applies the chosen codec to all future writes to the table, overriding the cluster or session default (`spark.sql.parquet.compression.codec`). You can override this table property with a DataFrame `.write.option("compression", "...")`. Setting the property doesn't rewrite existing files. To recompress existing data with your chosen codec, use [`OPTIMIZE table_name FULL`](https://docs.databricks.com/gcp/en/sql/language-manual/delta-optimize.md). For Unity Catalog managed Delta Lake tables, Databricks writes `parquet.compression.codec` explicitly (`ZSTD`) when it creates the table, so the separate Delta default `spark.databricks.delta.properties.defaults.parquet.compression.codec` has no effect. For new external Delta Lake tables, use `spark.databricks.delta.properties.defaults.parquet.compression.codec`.<br />Data type: `String`<br />Default: `ZSTD` |
| `parquet.format.version`                                        | The Parquet format version used when writing data files. Setting this to `2.12.0` enables advanced encodings, v2 data page headers, and `INT64` timestamps, which can improve query performance and reduce storage footprint.<br />Valid values are `1.0.0` and `2.12.0`, which correspond to releases from the [Apache Parquet format](https://parquet.apache.org/blog/parquet-format/).<br />This property can be set on Delta Lake and Apache Iceberg tables. Some OSS Iceberg readers might not support Parquet v2 encodings. See [Limitations](https://docs.databricks.com/gcp/en/tables/features/parquet-v2.md#limits).<br />See [Parquet v2](https://docs.databricks.com/gcp/en/tables/features/parquet-v2.md).<br />Data type: `String`<br />Default: `1.0.0`                                                                                                                                                                                                                                                                                                                              |
| `randomizeFilePrefixes`                                         | `true` to generate a random prefix for a file path instead of partition information.<br />Data type: `Boolean`<br />Default: `false`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| `randomPrefixLength`                                            | The number of characters to generate for random prefixes when `randomizeFilePrefixes` is `true`.<br />Data type: `Int`<br />Default: `2`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `setTransactionRetentionDuration`                               | The shortest duration within which new snapshots retain transaction identifiers (for example, `SetTransaction`s). New snapshots expire and ignore transaction identifiers older than or equal to the duration specified by this property. The `SetTransaction` identifier is used when making writes idempotent. See [Use `foreachBatch` for idempotent table writes](https://docs.databricks.com/gcp/en/structured-streaming/delta-lake.md#idempot-write) for details.<br />Data type: `CalendarInterval`<br />Default: (none)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `targetFileSize`                                                | The target file size in bytes or higher units for file tuning. For example, `104857600` (bytes) or `100mb`.<br />See [Control data file size](https://docs.databricks.com/gcp/en/tables/tune-file-size.md).<br />Data type: `String`<br />Default: (none)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| `tuneFileSizesForRewrites` (Delta Lake only)                    | `true` to tune file sizes so that operations that rewrite files, such as `MERGE`, run faster. This is useful for tables that frequently rewrite files. `false` to turn off this tuning.<br />When unset, Databricks auto-detects whether the table is rewrite-heavy and tunes file sizes for rewrite operations like `MERGE` and `OPTIMIZE` accordingly.<br />See [Control data file size](https://docs.databricks.com/gcp/en/tables/tune-file-size.md).<br />Data type: `Boolean`<br />Default: (none)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| `universalFormat.enabledFormats` (Delta Lake only)              | A comma-separated list of formats to generate metadata for, so that external clients can read the Delta Lake table (UniForm). Set to `iceberg` to generate Iceberg metadata. Setting `iceberg` requires either `enableIcebergCompatV2 = true` or `enableIcebergCompatV3 = true`. You can't enable both. See [Create and use managed tables with Apache Iceberg v3](https://docs.databricks.com/gcp/en/iceberg/iceberg-v3.md).<br />See [Read Delta Lake tables with Iceberg clients](https://docs.databricks.com/gcp/en/delta/iceberg-reads.md).<br />Data type: `String`<br />Default: (none)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
