/
New feature

COPY INTO

COPY INTO is a Databricks data engineering capability, introduced February 2020.

A retryable, idempotent SQL command that loads data from a file location into a Delta table, skipping files in the source location that it has already loaded.

  • Its idea of "already loaded" is stubborn: a file it has ingested is skipped on later runs even if you modify that file afterwards.
  • It can target a columnless placeholder Delta table and infer the schema on load, but until COPY INTO fills it, that table is unusable by anything else - INSERT INTO and MERGE INTO are not allowed to write to it.
  • The release note that introduced it made its pitch by complaint, noting that to load data into Delta Lake at the time you had to use Apache Spark DataFrame APIs.

Limitations: Databricks recommends streaming tables for a more scalable and robust file ingestion experience in SQL, and Auto Loader when ingesting directories with a very large number of files. A schemaless placeholder table cannot be written by INSERT INTO or MERGE INTO until COPY INTO has loaded data into it.

Open in REbricked →
Category
Data engineering
Introduced
February 2020
Announced at
Databricks Runtime 6.4 (Public Preview)
Also known as
COPY INTO command, COPY INTO SQL command
Verified
2026-09-27

Sources

Related in Data engineering