Domain 1 of 4 · Chapter 2 of 2

Create and Organize Objects in Unity Catalog

Address every object as catalog.schema.object

A production table in Unity Catalog has a name like prod.sales.orders, and that same three-part name identifies it from SQL, Python, or any BI tool attached to the workspace. Every governed object follows this three-level namespace, catalog.schema.object, which replaces the legacy two-level hive_metastore.schema.table layout. The metastore is the top-level container for a region; a catalog is the first level you create inside it; a schema (also called a database) is the second level; and the object itself, a table, view, volume, function, or model, is the third (Unity Catalog object model[1]).

The catalog is not just an organizational folder. It is the primary unit of data isolation in Unity Catalog, and schemas add a finer layer of organization beneath it (Unity Catalog best practices[2]). Because isolation lives at the catalog level, the common convention is one catalog per environment, for example dev, test, and prod. Separating environments only by schema inside a single shared catalog is the misread to avoid: it organizes the data but leaves every environment inside the same isolation boundary, so a grant on the catalog reaches all of them. Put each environment in its own catalog instead. Whoever runs the CREATE statement becomes the object's first owner, so Databricks recommends reassigning production catalogs and schemas to a group rather than leaving an individual as owner.

When data and its processing environment share the same isolation requirement, you can go further and bind a catalog to specific workspaces. Workspace-catalog binding restricts a catalog so only the workspaces you assign can reach it; access from an unbound workspace is denied even for a user who holds an explicit SELECT grant on a table inside it (Workspace-catalog binding[3]). That is how you keep a prod catalog reachable only from production workspaces. The figure below shows the full hierarchy from the metastore down to the object level.

Metastoreone per regionCatalogone per environment: dev / test / prodSchemagroups related objectsTablerows, DeltaViewsaved queryVolumefilesFunctionUDFModelML
The Unity Catalog three-level namespace: metastore, catalog, schema, then objects. Source: Azure Databricks Unity Catalog object model.

Create catalogs and schemas, and pin their storage

Two CREATE statements stand up the containers, and each carries a privilege gate and a storage decision. Start at the top: CREATE CATALOG makes a top-level container inside the metastore, and only a metastore admin or a principal granted the CREATE CATALOG privilege on the metastore can run it (Create catalogs[4]). A frequent slip is expecting CREATE CATALOG to give you a place to put tables directly; it does not. A catalog holds schemas, so a table needs a schema first, created with the two-level name CREATE SCHEMA catalog.schema (Create schemas[5]). A schema cannot be a top-level object.

The storage decision is where a Hive-metastore habit trips people up. In Unity Catalog you set a schema's managed storage with the MANAGED LOCATION clause, not LOCATION. LOCATION is the legacy Hive-metastore syntax; on a Unity Catalog schema it is rejected, and MANAGED LOCATION is the supported form (Create schemas[5]). Setting a MANAGED LOCATION requires the CREATE MANAGED STORAGE privilege on the external location (the Unity Catalog object that registers a cloud storage path) that covers the path. Omit the clause and the object inherits managed storage from the level above: managed storage resolves at the lowest level that sets it, the schema first, then the catalog, then the metastore (Managed storage best practices[2]).

Create a catalog, then a schema inside it

This pair creates a prod catalog and a sales schema, each with its own managed storage; the bracketed keyword is optional and other clauses are omitted:

CREATE CATALOG IF NOT EXISTS prod
  MANAGED LOCATION 'abfss://managed@company.dfs.core.windows.net/prod';
-- ...
CREATE SCHEMA IF NOT EXISTS prod.sales
  MANAGED LOCATION 'abfss://managed@company.dfs.core.windows.net/prod/sales';

Each MANAGED LOCATION path must sit under a Unity Catalog external location you hold CREATE MANAGED STORAGE on. Drop the clause and that object inherits managed storage from its parent instead.

Managed vs external: who owns the files and the drop

One distinction decides who owns your data files and what a DROP destroys, and it applies the same way to tables and to volumes: managed versus external. In a managed object, Unity Catalog owns both the governance and the underlying files, which live in managed storage. In an external object, Unity Catalog governs access to the metadata, but the files stay in a cloud location you manage (Managed vs external assets[2]).

For tables, a managed table is the default and recommended type. It stores rows in the Delta Lake format unless you request USING iceberg, and you can create one empty, with CREATE TABLE AS SELECT (CTAS), or with CREATE OR REPLACE TABLE (Managed tables[6]). Dropping a managed table deletes both the metadata and the data files; Unity Catalog keeps them recoverable with UNDROP for a default of seven days, then removes them from cloud storage. An external table is created with a LOCATION clause pointing at a path under a Unity Catalog external location, and DROP TABLE removes only the metadata and leaves the files untouched (External tables[7]). That difference is the exam's favorite table trap: if the files must survive the drop, the answer is an external table.

Volumes extend the same model to non-tabular data. A volume is a Unity Catalog object under a schema that governs files of any format, such as images, CSVs, and model artifacts, reached through the path /Volumes/catalog/schema/volume (Volumes[8]). A managed volume stores its files in the schema's managed storage; an external volume, created with CREATE EXTERNAL VOLUME ... LOCATION, registers an existing path under an external location (Create volumes[9]). The drop rule mirrors tables exactly: dropping a managed volume marks its files for deletion, while dropping an external volume leaves them in place. The figure groups the four objects by the only question that matters at drop time.

ManagedUnity Catalog owns the filesManaged tableManaged volumeExternalUnity Catalog governs metadata onlyExternal tableExternal volumeDROP deletes the filesDROP leaves the files
Managed objects: Unity Catalog owns the files, so DROP deletes them; external objects keep their files. Source: Azure Databricks tables and volumes docs.

Views and materialized views

A view and a materialized view read almost the same in SQL, but one stores data and one does not, and that single fact drives every question about them. A standard view is a read-only object that saves the text of a SELECT query; creating it writes no data, and only the query text is registered to the schema (Views[10]). Each time you read the view, Unity Catalog re-runs its query against the base tables, so the results are always current, and the view can restrict or reshape the columns it exposes without copying anything.

A materialized view precomputes and stores its results in an underlying managed table, then keeps them up to date as the source tables change (Views[10]). When you create one, Unity Catalog automatically provisions a serverless pipeline to build and refresh it, billed as serverless Lakeflow Spark Declarative Pipelines usage; the refresh runs incrementally, merging only changed rows when the query allows, and falls back to a full recompute when it cannot (Standalone materialized views[11]). You refresh it on a schedule or on update. The trade the exam probes: a materialized view spends storage and a scheduled refresh to make repeated reads fast, while a standard view spends nothing and recomputes on every read. So a materialized view stores data and must be refreshed; a standard view does neither.

Precompute a daily aggregate as a materialized view

This materialized view stores a per-day sales total so a dashboard reads it instantly; the refresh schedule and other options are omitted:

CREATE OR REPLACE MATERIALIZED VIEW prod.sales.daily_totals AS
SELECT date, sum(amount) AS total
FROM prod.sales.orders
GROUP BY date;
-- ...

Because daily_totals is materialized, the sum is computed once per refresh and stored, not recomputed on every dashboard load.

Query external systems in place with federation

Suppose an operational PostgreSQL database holds live order status, and an analyst needs to join it against lakehouse tables for a quick report without waiting for an ingestion pipeline to copy it in. Lakehouse Federation is the Azure Databricks feature for exactly this: governed, read-only access to an external system that you query in place (Lakehouse Federation[12]).

It takes two objects, created in order. First a connection, a Unity Catalog securable that stores the source's host, JDBC URL, and credentials. Then a foreign catalog, created from that connection, which mirrors the external database's schemas and tables as Unity Catalog objects so they appear alongside your other catalogs (Lakehouse Federation[12]). Once you grant privileges on the foreign catalog, queries against it are pushed down to the source and run in place; no data is copied into Unity Catalog managed storage. PostgreSQL is one of many supported sources here, alongside MySQL, SQL Server, Oracle, Snowflake, Amazon Redshift, Azure Synapse, Google BigQuery, and other Databricks workspaces.

The contrast to hold onto: only a foreign catalog queries the source in place. An ingestion pipeline (Lakeflow Connect, Auto Loader, or COPY INTO) or a managed table built from the source would copy the data into Databricks storage instead. When higher data volumes and lower latency matter more than avoiding a copy, Databricks actually recommends ingesting with Lakeflow Connect over federating. The figure traces the connection, the foreign catalog, and the in-place query.

Connectionstores host + credentialsForeign catalogmirrors source schemasSource databasePostgreSQL, SQL Serverusesquery pushed downRead-only, queried in placeno data copied into Unity Catalog storage
Lakehouse Federation: a connection and foreign catalog let queries run in place against the source with no copy. Source: Azure Databricks query federation docs.

Self-service discovery with AI/BI Genie

Business users often need an answer, not a query editor. An AI/BI Genie Agent (formerly called a Genie space) is a domain-specific, natural-language interface where a user asks a question in plain English and Genie returns the generated SQL, a results table, and a visualization (Genie[13]). It runs over a curated set of Unity Catalog tables that a data analyst registers to the agent, which turns ad hoc data discovery into self-service without anyone writing SQL.

Accuracy comes from curation, not magic. The analyst who builds the agent supplies general instructions in plain language, example SQL queries, SQL expressions that encode business semantics, and verified answers to trusted questions; together these steer how Genie interprets domain terms and business logic (Tune Genie Agent quality[14]). A vague metric like active customer becomes reliable only once an instruction or example pins down what it means.

One boundary is worth stating plainly, because it is a natural misread. Genie answers from the curated tables it was given plus those instructions, and access is still governed by the querying user's Unity Catalog permissions; it does not roam the whole metastore looking for data (Genie Agents concepts[15]). Widening what Genie can answer means adding tables and instructions to the agent, not granting it blanket access.

Exam-pattern recognition

Most questions on creating and organizing Unity Catalog objects reduce to picking the right object or clause under a stated constraint. Read the constraint in the stem, then match it.

  • Isolate production data from development: create a separate catalog per environment, and bind it to the production workspaces if the environment itself must be restricted. The catalog is the isolation unit; separating environments by schema inside one catalog does not isolate them (best practices[2]).
  • Set a schema's managed storage: use MANAGED LOCATION. LOCATION is Hive-metastore syntax and is rejected on a Unity Catalog schema (create schemas[5]).
  • The files must survive a drop: choose an external table or external volume, defined with LOCATION. A managed DROP deletes the underlying files (managed tables[6]).
  • Speed up an expensive, repeated query: a materialized view precomputes and stores results and refreshes them; a standard view recomputes on every read (materialized views[11]).
  • Query an external database without copying it: create a connection, then a foreign catalog, and query in place. An ingestion pipeline or managed table would copy the data (Lakehouse Federation[12]).
  • Govern images, CSVs, or model artifacts: register a volume and reach files at /Volumes/catalog/schema/volume (volumes[8]).
  • CREATE CATALOG versus CREATE SCHEMA: CREATE CATALOG builds a top-level container; a table needs a schema created as CREATE SCHEMA catalog.schema (create catalogs[4]).
  • Self-service natural-language questions for business users: an AI/BI Genie Agent over a curated set of Unity Catalog tables, steered by instructions and examples (Genie[13]).

Managed vs external tables and volumes: storage and DROP

ObjectWhere data livesCreated withOn DROP
Managed tableCatalog or schema managed storageCREATE TABLE (Delta by default) or CTASDeletes metadata and data files
External tableA path under a Unity Catalog external locationCREATE TABLE ... LOCATIONDeletes metadata only; files remain
Managed volumeSchema managed storageCREATE VOLUMEMarks the volume's files for deletion
External volumeA path under a Unity Catalog external locationCREATE EXTERNAL VOLUME ... LOCATIONRemoves the volume; files remain

Decision tree

Persisting tabular rows?Files survive DROP?Non-tabular files?Query an external DB?Precompute for reuse?Managed tableExternal tableVolumeForeign catalogexternal DB, in placeMaterialized viewViewYesNoNoYesYesNoYesNoYesNo

Sharp facts the exam loves — give these one last read before exam day.

Cheat sheet

Sharp facts the exam loves — scan these before test day.

Unity Catalog addresses data as catalog.schema.object

Unity Catalog organizes every data object in a three-level namespace of catalog.schema.object (tables, views, volumes, functions, and models), replacing the legacy two-level hive_metastore.schema.table layout.

5 questions test this
Use a separate catalog per environment for data isolation

The catalog is the primary unit of data isolation in Unity Catalog, so a common naming convention creates a distinct catalog per environment (for example dev, test, and prod) to segregate data and permissions.

Trap Separating environments only by schema inside one shared catalog weakens the isolation boundary.

7 questions test this
Bind a catalog to specific workspaces to restrict its access

Workspace-catalog binding restricts a catalog so it is accessible only from designated workspaces, enforcing environment isolation and controlled external sharing across a metastore shared by several workspaces.

5 questions test this
CREATE CATALOG makes a top-level container in the metastore

CREATE CATALOG creates the top-level container within the metastore; an optional MANAGED LOCATION sets where its managed tables and volumes store data, otherwise they inherit managed storage from the metastore.

Trap CREATE CATALOG builds a catalog, not a schema; a contained schema needs CREATE SCHEMA catalog.schema.

16 questions test this
Creating a catalog requires the CREATE CATALOG metastore privilege

Only a metastore admin or a principal granted the CREATE CATALOG privilege on the metastore can create a catalog, and the creator becomes its owner with full control over the new object.

Set a schema's storage with MANAGED LOCATION, not LOCATION, in Unity Catalog

CREATE SCHEMA catalog.schema MANAGED LOCATION '' sets a schema's managed storage in Unity Catalog; the LOCATION clause is a Hive-metastore-only syntax and is rejected for Unity Catalog schemas.

Trap LOCATION is not supported for a Unity Catalog schema; use MANAGED LOCATION instead.

9 questions test this
A schema is created two-level as catalog.schema

A schema (database) groups tables, views, and volumes and must be created inside a catalog with the two-level name catalog.schema; it cannot be created as a top-level object.

13 questions test this
MANAGED LOCATION requires CREATE MANAGED STORAGE on an external location

Setting a schema's MANAGED LOCATION requires the CREATE MANAGED STORAGE privilege on the external location that covers the path; without an explicit managed location the schema inherits managed storage from its catalog or the metastore.

Volumes are Unity Catalog objects that govern non-tabular files

A volume is a Unity Catalog object under a schema that governs access to non-tabular data such as images, CSV files, and model artifacts, accessed through the path /Volumes/catalog/schema/volume.

15 questions test this
Managed volumes use Unity Catalog storage; external volumes point at a location

A managed volume stores its files in the schema's managed storage and is fully lifecycle-managed by Unity Catalog, whereas an external volume registers an existing path under an external location for data that Databricks does not own.

Trap Dropping a managed volume deletes its files; dropping an external volume leaves the files in place.

10 questions test this
A view is a stored read-only query that materializes no data

A view is a saved SELECT query that is evaluated each time it is read; it stores no data of its own and can restrict or reshape the columns exposed from its base tables.

16 questions test this
A materialized view stores precomputed results refreshed incrementally

A materialized view precomputes and stores query results and refreshes them incrementally through a Lakeflow declarative pipeline on serverless compute, speeding repeated reads at the cost of storage and scheduled refresh.

Trap A materialized view stores data and must be refreshed; a standard view does neither.

13 questions test this
A table persists data, defaulting to the Delta Lake format

A Unity Catalog table stores rows and columns using the Delta Lake format by default, and can be created empty, with CREATE TABLE AS SELECT (CTAS), or with CREATE OR REPLACE TABLE.

Lakehouse Federation needs a connection first, then a foreign catalog

To federate an external database you first create a connection object that stores the server host and credentials, then create a foreign catalog that uses that connection to mirror the external database's schemas in Unity Catalog.

8 questions test this
Federated queries run in place with no data copy

A foreign catalog runs Lakehouse Federation queries directly against the source system so its schemas and tables appear alongside other Unity Catalog objects and are queried in place, with no data copied into Databricks-managed storage.

Trap An ingestion pipeline or a managed table would copy the data; only a foreign catalog queries the source in place.

13 questions test this
Dropping a managed table deletes its underlying data

A managed table stores its data files in Unity Catalog managed storage, so DROP TABLE removes both the table metadata and the underlying data files.

Trap Dropping an external table removes only the metadata and leaves the files intact.

12 questions test this
An external table is defined with LOCATION and keeps its data on drop

An external table is created with a LOCATION clause pointing at a path under an external location, so Unity Catalog governs only its metadata and DROP TABLE leaves the underlying files untouched.

13 questions test this
AI/BI Genie answers natural-language questions over a curated data set

An AI/BI Genie space lets business users ask natural-language questions that Genie converts to SQL over a curated set of Unity Catalog tables, enabling self-service data discovery without writing queries.

9 questions test this
Genie instructions and example queries steer accurate answers

Configuring Genie general instructions, example SQL queries, and trusted or certified answers guides how Genie interprets domain terms and business logic, improving the accuracy of the answers it generates for data discovery.

Trap Genie relies on the curated tables plus its instructions, not on unrestricted access to the whole metastore.

12 questions test this

References

  1. What is Unity Catalog?
  2. Unity Catalog best practices
  3. Workspace-catalog binding
  4. Create catalogs
  5. Create schemas
  6. Unity Catalog managed tables for Delta Lake and Apache Iceberg
  7. Work with external tables
  8. What are Unity Catalog volumes?
  9. Create and manage Unity Catalog volumes
  10. What is a view?
  11. Use standalone materialized views
  12. Connect to external databases and catalogs
  13. Genie Agents
  14. Tune Genie Agent quality
  15. Genie Agents concepts