Skip to content
BENIBIX Learn

Zero-Copy Clone

Also known as Zero-Copy Cloning, Table Clone, Shallow Clone

A fast copy of a table. It shares its files until one side changes.

Think of it like

It is like a photocopy that only uses ink where you write on it. The rest still points at the first page.

Example

A team clones its 4 TB sales database each morning for testing. The clone is ready fast, and testers can change it without touching the real data.

Why it matters

Testing on real data used to mean slow, costly copies. A clone makes a safe test copy cheap.

Definition

A zero-copy clone is a copy of a table, schema or database made without copying the data. The clone points at the same stored files as the source. New files are written only when one side changes rows. So a clone of a huge table is ready in moments and costs almost nothing at first. Snowflake can make one, and so can lake formats such as Delta Lake.

Example code

sql
CREATE TABLE orders_test CLONE orders;
A full copy of orders for testing. No data is copied until a row changes.
Both tables point at the same three files. Only the clone's own changes get a new file.

Common mistake

Thinking a clone stays free. Every row you change in it writes new files, and those cost storage.

Key takeaways

  1. 1
    Shares files. Nothing is copied at the start.
  2. 2
    Writes on change. New files only for changed rows.
  3. 3
    Fast. Ready in moments, even when huge.