
Ultimate access to all questions.
A data engineer wants to create a data entity from a couple of tables. The data entity must be used by other data engineers in other sessions. It also must be saved to a physical location. Which of the following data entities should the data engineer create?
A
Database
B
Function
C
View
D
Temporary view
E
Table
Explanation:
The correct answer is E. Table.
Let's analyze each option:
A. Database - A database is a collection of tables and other objects, but it's not a data entity created from tables. It's a container for organizing tables.
B. Function - Functions are used for data transformation, not for creating data entities from tables.
C. View - A view is a virtual table based on a SELECT query. While it can be created from multiple tables and can be used by other data engineers, views do not save data to a physical location. Views are just saved queries that execute when accessed.
D. Temporary view - Temporary views are session-scoped and cannot be used by other data engineers in other sessions. They also don't save data to physical storage.
E. Table - A table is the correct choice because:
Tables in Databricks store data physically in cloud storage (like ADLS, S3, or GCS), making the data available across sessions and to multiple users. The data engineer can create a table using SQL like:
CREATE TABLE target_table AS
SELECT * FROM table1
JOIN table2 ON table1.id = table2.id;
CREATE TABLE target_table AS
SELECT * FROM table1
JOIN table2 ON table1.id = table2.id;
This creates a physical table that meets all the requirements: created from multiple tables, saved to physical location, and accessible across sessions.