TBLPROPERTIES saves named settings on a table. Use it to record custom metadata, choose an Iceberg format version at creation, or control supported options for later writes.
This page covers Unified’s Iceberg table path. The properties a catalog can store are broader than the settings the Unified writer actually uses. A saved key does not, by itself, prove that a writer feature is supported.
Create a table with properties
Choose a writable Iceberg catalog in Workbench. Use an unusedmaintenance_docs namespace, or replace that name throughout the example. This script uses inline data and replaces only properties_demo.
docs.owner is analytics, and the saved compression codec is zstd.
Property keys and values are quoted strings in these examples. Use the full property key, including dots and hyphens, exactly as shown.
Inspect all properties or one key
zstd. Asking for a key that is not saved reports a missing-property error.
Saved properties do not necessarily list every effective default. An omitted compression key can still use the writer’s default. Iceberg’s format version is special metadata; it is not handled as an ordinary custom key in every properties result. Use the table definition and extended description when reviewing the format.
Change later write settings
This block reuses the table created above. It changes the compression for the next insert and sets a custom owner value.gzip. The table now has four rows and total amount 100. Existing files keep their earlier encoding. The insert uses the settings resolved for its own write.
Changing properties does not convert old files to the new codec or resize them. To rewrite existing files, use a suitable maintenance action or a deliberate data rewrite. Confirm the physical output through table inspection.
Remove a saved property
IF EXISTS tolerates a key that has already been removed. Without it, removing a missing property fails. Removing the explicit compression level lets the next write use the remaining codec’s default level. It does not reset the codec or rewrite existing files.
Iceberg format version
New Iceberg tables default to v3. Explicitly request v2 at creation when using the current native maintenance provider:format-version changes the actual Iceberg table format. It is not a label. The Iceberg path supports version increases through supported versions, rejects downgrades, and does not allow this key to be unset.
The following is an upgrade template, rather than a required step in the practice flow:
2 is not a supported downgrade.
Supported file and Parquet write properties
A row group is a block of rows inside a Parquet file. Pages hold smaller blocks of column values. A dictionary stores repeated values that pages can refer to by code.
The writer accepts
uncompressed, snappy, zstd, gzip, brotli, lz4, and lz4_raw. LZO is unsupported. A compression level must be valid for its codec. A level paired with Snappy, LZ4, or uncompressed output is rejected.
Sizes and row limits must be positive. File and encoding targets are capped by runtime memory and buffer limits. Batch boundaries can produce small files even when the configured file target is large. A file-size setting is a target, not an exact output size.
Content-defined chunking
Content-defined chunking chooses Parquet page boundaries from the data values before encoding and compression. It is separate from file compaction and from row-level change data capture.
An optional example for the existing practice table:
Table settings, write options, and maintenance arguments
Supported per-write overrides take priority over table properties, then encoder defaults. They do not change the saved properties. SQL
INSERT has no per-write OPTIONS clause. See options for one DataFrame write.
The default normal-write target is 512 MiB. The default maintenance compaction target is 128 MiB before instance overrides. They are separate settings. Choose maintenance arguments for the maintenance call rather than assuming a table write target configures every rewrite.
Use PARTITIONED BY for a table’s partition transforms. Storing an arbitrary partition or sort key as a property does not enable partition evolution, enforced write sort order, per-column Parquet controls, or writer distribution in this path.
Validation and custom metadata
Custom properties such asdocs.owner can be saved as table metadata. They do not change the writer unless a supported feature reads them.
Unknown write.parquet.* and write.target-* keys are rejected when a write is planned. Invalid sizes or codec settings may be saved by the catalog and then rejected by the writer. Check both the saved properties and the next write’s outcome; property storage alone is not end-to-end validation.
The Streaming Iceberg sink has its own connector options. Do not copy these dotted Unified write properties into a Streaming sink without checking the Streaming sink options.