Courseiva

Databricks-DA-Assoc Data Modeling with Databricks SQL Practice Question

A data analyst needs to create a view in Databricks SQL that combines data from two tables and applies a filter. The view should be accessible to other users in the same Unity Catalog schema. Which SQL statement should the analyst use?

⚠ Common exam trap

Watch out — candidates often confuse a standard view with a materialized view or a table, which have different persistence and refresh characteristics.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

CREATE VIEW my_view AS SELECT ... FROM table1 JOIN table2 WHERE ...;

The CREATE VIEW statement creates a persistent, virtual view that other users can access if they have permissions. It dynamically reflects changes in the underlying tables and does not store data. A table would duplicate data and not stay current. A materialized view adds unnecessary complexity, and a temporary view is not shared across users.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    CREATE MATERIALIZED VIEW my_view AS SELECT ... FROM table1 JOIN table2 WHERE ...;

    Why it's wrong here

    A materialized view stores precomputed results and requires refresh to stay current. While it can improve performance, it is not necessary for a simple view and adds maintenance overhead. The scenario does not mention performance requirements that would justify materialization. The analyst simply needs a view, so a standard view is sufficient and simpler.

  • ✗

    CREATE TEMPORARY VIEW my_view AS SELECT ... FROM table1 JOIN table2 WHERE ...;

    Why it's wrong here

    A temporary view is session-scoped and is dropped when the session ends. It is not accessible to other users in the schema. The requirement is for the view to be accessible to other users, so a temporary view does not meet that need. It is useful for ad-hoc queries within a session but not for sharing persistent logic.

  • ✗

    CREATE TABLE my_view AS SELECT ... FROM table1 JOIN table2 WHERE ...;

    Why it's wrong here

    CREATE TABLE AS SELECT creates a physical table that stores the query results at creation time. It does not stay in sync with the underlying tables when they change. The analyst needs a view that dynamically reflects current data, so a table is not appropriate. It also duplicates storage and requires refresh to update, which is not ideal for a view-like object.

  • ✓

    CREATE VIEW my_view AS SELECT ... FROM table1 JOIN table2 WHERE ...;

    Why this is correct

    The CREATE VIEW statement creates a virtual view that can be queried like a table. It stores the query definition, not the data. This is the standard way to create a view in Databricks SQL, and it will be accessible to users with appropriate permissions on the schema. It meets the requirement of combining tables and applying a filter without duplicating data.

About these practice questions

This Databricks-DA-Assoc question is part of Courseiva's 291-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written and reviewed by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

Last reviewed September 2026 · checked against the official Databricks exam blueprint

This Databricks-DA-Assoc practice question is part of Courseiva's free Databricks certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the Databricks-DA-Assoc exam.