Skip to documentation
Documentation
StableVerified September 2, 2026
CLI

SQL and catalog administration

Query lake data and, with the appropriate role, register and optimize the metadata that makes it fast.

Query

sql
SELECT region, count(*) AS n
FROM OpenSource.public.events
GROUP BY region
ORDER BY n DESC
LIMIT 10;

Register a lake table

sql
CREATE CATALOG IF NOT EXISTS Analytics WITH (
  storage = 'adls', account = 'kaveonlake', container = 'opensource',
  root = 'snapshots/current', credential = 'workload-identity:kaveon-reader'
);
CREATE SCHEMA IF NOT EXISTS Analytics.sales;
CREATE TABLE IF NOT EXISTS Analytics.sales.orders WITH (
  location = 'sales/orders', format = 'parquet'
);

Measure and optimize

sql
ANALYZE Analytics.sales.orders WITH (sketches = true);
SHOW STATS FOR Analytics.sales.orders;
DESCRIBE DETAIL Analytics.sales.orders;
OPTIMIZE Analytics.sales.orders;

Registration reads the table metadata in place; it does not copy rows. The full SQL compatibility matrix and lifecycle rules remain in the CLI reference.