Tech, ExplainedData platforms and AI
Part

Open table formats

Your data, readable by any engine.

INSIDE: DATA LAKEHOUSEHOW IT WORKS · CORRECTING 2,000 MOTOR CLAIMSThe claims tableholds 8 crorerows in Parquetfiles; thecurrent versionis snapshot 417A nightly jobmust correct2,000 claims,held in 3 ofthose filesIt writes 3 newfiles of 40 MBeach andsnapshot 418,which lists themin place of theold 3Until theswitch,every readerstill seessnapshot 417At 2:00 a.m.,one pointermoves tosnapshot 418 ina single stepTwo differentengines readsnapshot 418 thenext morning;417 is kept fortime travelINSIDE: DATA LAKEHOUSEHOW IT WORKS · CORRECTING 2,000 MOTOR CLAIMSThe claims table holds 8crore rows in Parquetfiles; the currentversion is snapshot 417A nightly job mustcorrect 2,000 claims,held in 3 of those filesIt writes 3 new files of40 MB each and snapshot418, which lists them inplace of the old 3Until the switch, everyreader still seessnapshot 417At 2:00 a.m., one pointermoves to snapshot 418 ina single stepTwo different enginesread snapshot 418 thenext morning; 417 is keptfor time travelINSIDE: DATA LAKEHOUSE ·CORRECTING 2,000 MOTOR CLAIMSThe claims table holds 8 crore rows inParquet files; the current version issnapshot 417↓A nightly job must correct 2,000 claims,held in 3 of those files↓It writes 3 new files of 40 MB each andsnapshot 418, which lists them in placeof the old 3↓Until the switch, every reader still seessnapshot 417↓At 2:00 a.m., one pointer moves tosnapshot 418 in a single step↓Two different engines readsnapshot 418 the next morning;417 is kept for time travel
An open table format corrects 2,000 motor claims by writing 3 new files and a new snapshot, then moves one pointer from snapshot 417 to 418, so every reader sees either the old table or the new one.
opens a page inside this one a page in the same scene a page in another scene a concept page a label only, with no page

Open table formats are shared, public rules for storing a database table as ordinary files in a data lake, so that more than one piece of software can read and change the same table safely. The best-known are Apache Iceberg, Delta Lake and Apache Hudi. All three are open source, so anyone may use them free of charge. They are the layer that turns a data lakehouse from a pile of files into tables.

In a lake, one table is stored as many data files, usually in a column-by-column file format called Parquet, in object storage. The files alone cannot answer simple questions. Which files belong to the table today? Which were replaced yesterday? What are the column names? An open table format answers these questions in metadata files, small files kept next to the data. Each time someone changes the table, the change writes new data files and a new snapshot. A snapshot is a list of exactly which files make up the table at that moment. Finally, one pointer is switched to the new snapshot, in a single step.

That single step gives three useful properties. First, a reader never sees a half-finished change, because it reads either the old snapshot or the new one. Second, old snapshots are kept for some time, so a team can query the table exactly as it was last week. This is called time travel. Third, a column can be added or renamed without rewriting the data files.

Here is a typical case. An insurance company keeps its motor claims, 8 crore rows, as a table in its lake. The current version is snapshot 417. One night, a job must correct 2,000 claims whose amounts were entered wrongly. Those claims sit in 3 of the table's data files. The job writes 3 new files of 40 MB each, holding the corrected rows, and creates snapshot 418, which lists the new files in place of the old ones. While the job runs, an analyst's report keeps reading snapshot 417 and gets consistent figures. At 2:00 a.m., the pointer moves to 418. The next morning, the claims team reads the table through one engine, and the fraud team reads the same files through another.

Why does "open" matter? Because the format is public, any engine that supports it can read the table: a data warehouse service, a real-time analytics database or a large processing job. So the company can change its query engine later without moving its data. This is the main defence against vendor lock-in in data. Some companies sell services that keep these tables tidy, for example by merging many small files into fewer large ones.

How is a table format different from a file format such as Parquet? A file format describes how the data inside one file is laid out. A table format describes which files together make up one table, and how the table changes over time.

Tech, Explained is a part of ingrid.fyi. Every page explains one piece of technology in plain words.