Databricks Data Engineer Associate exam dumps

Databricks Data Engineer Associate practice question 100 of 532

Databricks Certified Data Engineer Associate. Associate level, Databricks. Free question with the correct answer and a full explanation.

Databricks Data Engineer Associate Question 100

Select 3

You are working with a large CSV file stored in a Databricks workspace. You need to reference this file in multiple queries during your session, and later make one of the references persist for future use. Which of the following steps should you take?

  1. A

    Use CREATE OR REPLACE VIEW to create a view referencing the file.

  2. B

    Use CREATE TEMPORARY VIEW to create a temporary view referencing the file.

  3. C

    Use a Common Table Expression (CTE) to temporarily reference the file within a specific query.

  4. D

    Use CREATE GLOBAL TEMP VIEW to create a globally accessible view referencing the file.

  5. E

    Use INSERT INTO to load the file into a new table and reference it directly.

Show answer and explanation

Correct answers: A, B, C

Explanation

To reference a file in Databricks, you can use a view, a temporary view, or a CTE depending on the scope of usage. A persistent view (created using CREATE OR REPLACE VIEW) is suitable if you need a reusable reference for future queries. A temporary view (CREATE TEMPORARY VIEW) is ideal for session-specific tasks. A CTE is appropriate for a single query. Using a global temporary view or loading the file into a table is unnecessary unless explicitly required by additional use cases.

  • A. Correct.

    Correct. A view created using CREATE OR REPLACE VIEW is persistent and allows you to reference the file for future use.

  • B. Correct.

    Correct. A temporary view created using CREATE TEMPORARY VIEW is valid for the duration of the session and works well for session-specific tasks.

  • C. Correct.

    Correct. A CTE is a great choice for referencing the file within a single query, but it is not persistent beyond that query.

  • D. Incorrect.

    Incorrect. While CREATE GLOBAL TEMP VIEW creates a globally accessible view, it is not needed in this scenario as the problem does not specify global accessibility requirements.

  • E. Incorrect.

    Incorrect. Loading the file into a new table is not necessary in this case because the requirement is to reference the file, not to permanently store it in a table.

Timed practice exam

Take a Databricks Data Engineer Associate practice test under exam conditions

45 questions in 90 minutes, drawn from this bank, with a score report and a per-question review when you finish.

Start timed exam