Docsity

Databricks Data Analyst Ultimate Exam, Exams of Technology

Toggle sidebar
bg1
Databricks Data Analyst Ultimate Exam
**Question 1. Which component of the Databricks Lakehouse architecture provides
ACID transactions and schema enforcement?**
A) Unity Catalog
B) Delta Lake
C) Mosaic AI
D) Lakeflow Jobs
Answer: B
Explanation: Delta Lake adds ACID transaction support and schema enforcement on
top of the data lake, turning it into a reliable storage layer for the Lakehouse.
**Question 2. In Unity Catalog, what does the three-level namespace
`$catalog.schema.table` represent?**
A) Physical file location on DBFS
B) Logical hierarchy for data governance
C) Execution engine configuration
D) Network security zone
Answer: B
Explanation: Unity Catalog organizes objects using a three-level namespace
(catalog → schema → table) to enable centralized governance and fine-grained
permissions.
**Question 3. Which type of SQL warehouse in Databricks is billed per second of
compute usage and automatically scales to zero when idle?**
A) Classic SQL Warehouse
B) Serverless SQL Warehouse
C) Delta Live Tables Warehouse
D) Mosaic AI Warehouse
Answer: B
Explanation: Serverless SQL Warehouses are on-demand, per-second billed, and
automatically scale down to zero when not in use.
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32

Partial preview of the text

Download Databricks Data Analyst Ultimate Exam and more Exams Technology in PDF only on Docsity!

Question 1. Which component of the Databricks Lakehouse architecture provides ACID transactions and schema enforcement? A) Unity Catalog B) Delta Lake C) Mosaic AI D) Lakeflow Jobs Answer: B Explanation: Delta Lake adds ACID transaction support and schema enforcement on top of the data lake, turning it into a reliable storage layer for the Lakehouse. Question 2. In Unity Catalog, what does the three-level namespace $catalog.schema.table represent? A) Physical file location on DBFS B) Logical hierarchy for data governance C) Execution engine configuration D) Network security zone Answer: B Explanation: Unity Catalog organizes objects using a three-level namespace (catalog → schema → table) to enable centralized governance and fine-grained permissions. Question 3. Which type of SQL warehouse in Databricks is billed per second of compute usage and automatically scales to zero when idle? A) Classic SQL Warehouse B) Serverless SQL Warehouse C) Delta Live Tables Warehouse D) Mosaic AI Warehouse Answer: B Explanation: Serverless SQL Warehouses are on-demand, per-second billed, and automatically scale down to zero when not in use.

Question 4. When creating a table in Databricks, what is the primary difference between a Managed table and an External table? A) Managed tables store data in DBFS; External tables reference data outside the lakehouse. B) Managed tables support ACID; External tables do not. C) Managed tables can be accessed only via notebooks; External tables only via SQL. D) Managed tables automatically enforce row-level security; External tables cannot. Answer: A Explanation: Managed tables have their data controlled by Databricks (stored in the default location), while External tables point to data stored elsewhere (e.g., S3, ADLS). Question 5. Which Databricks feature allows you to incrementally ingest new files from cloud storage with exactly-once semantics? A) UI-based Upload B) Auto Loader C) Delta Sharing D) Partner Connect Answer: B Explanation: Auto Loader continuously monitors cloud storage, infers schema, and ingests new files with exactly-once guarantees. Question 6. In Delta Live Tables (DLT), what does the “expectations” feature enable? A) Automatic model training B) Data quality checks that can abort pipelines on failure C) Real-time dashboard generation D) Automatic clustering of tables Answer: B Explanation: Expectations let you define data quality rules; if they fail, DLT can halt or flag the pipeline.

A) Bronze B) Silver C) Gold D) Platinum Answer: A Explanation: The Bronze layer stores raw, immutable data, serving as the ingestion landing zone. Question 11. Which Unity Catalog feature provides row-level security based on user attributes? A) Column masking B) Data lineage C) Row-level security policies (RLS) D) Table tagging Answer: C Explanation: RLS policies let you define filter expressions that are applied per-user, restricting visible rows. Question 12. What does the DESCRIBE HISTORY command in Delta Lake allow you to do? A) Show the physical file layout on disk. B) List all users who have accessed the table. C) View versioned metadata and perform time travel. D) Export the table to CSV. Answer: C Explanation: DESCRIBE HISTORY returns a table of commit metadata, enabling auditing and time-travel queries. Question 13. Which of the following is NOT a supported ingestion method in Databricks? A) UI-based file upload B) Auto Loader

C) Kafka Streams source directly into Delta Lake D) Manual SFTP copy to DBFS only Answer: D Explanation: While you can copy via SFTP, Databricks does not provide a native “manual SFTP” ingestion UI; ingestion is done through DBFS mount, Auto Loader, or streaming sources. Question 14. When you want to join tables across two different Unity Catalog catalogs, which SQL feature must you use? A) CROSS DATABASE JOIN syntax (catalog1.schema1.table1 JOIN catalog2.schema2.table2) B) Federated query engine only available in Classic Warehouse C) DataFrame API only D) You cannot join across catalogs; you must copy data first. Answer: A Explanation: Fully qualified names allow cross-catalog joins directly in SQL. Question 15. Which statement best describes the purpose of the Databricks Assistant? A) It monitors cluster health and restarts failed nodes. B) It provides AI-driven suggestions for writing, debugging, and optimizing SQL code. C) It automatically generates data visualizations from raw tables. D) It enforces security policies on notebooks. Answer: B Explanation: The Assistant uses generative AI to help users craft and improve SQL queries. Question 16. In a Databricks dashboard, which widget type is most appropriate for showing a single numeric KPI that updates in real time? A) Bar chart B) Line chart

Answer: B Explanation: Trusted assets are vetted SQL objects (tables, views, queries) that Genie uses to answer natural-language questions accurately. Question 20. What is the primary benefit of liquid clustering in Delta Lake? A) Automatic partitioning based on data size. B) Dynamic reorganization of data files to improve query pruning without manual re-clustering. C) Real-time streaming ingestion. D) Encrypted storage of sensitive columns. Answer: B Explanation: Liquid clustering continuously optimizes file layout based on query patterns, reducing the need for manual OPTIMIZE commands. Question 21. Which SQL function would you use to compute a running total of sales across ordered dates? A) SUM() OVER (ORDER BY date ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW) B) GROUP BY date C) CUME_DIST(date) D) LAG(sales) Answer: A Explanation: The window function with SUM() OVER and an ordered frame computes a cumulative total. Question 22. In Databricks, what does the GRANT SELECT ON TABLE analytics.sales TO ROLE analyst; statement do? A) Grants the analyst role permission to read the sales table. B) Grants the role the ability to create new tables in the catalog. C) Grants write access to the sales table. D) Revokes all other permissions from the analyst role. Answer: A

Explanation: GRANT SELECT provides read-only access to the specified table for the role. Question 23. Which of the following is a valid way to tag a table in Unity Catalog for better discovery? A) ALTER TABLE analytics.sales SET TAG 'PII' = 'true'; B) ALTER TABLE analytics.sales SET PROPERTY 'PII' = 'true'; C) COMMENT ON TABLE analytics.sales IS 'PII:true'; D) CREATE TAG analytics.sales PII; Answer: A Explanation: Unity Catalog supports key-value tags via SET TAG to annotate objects for discovery and governance. Question 24. When using Auto Loader, which option ensures that schema evolution (adding new columns) is automatically applied? A) cloudFiles.schemaLocation B) cloudFiles.inferColumnTypes C) cloudFiles.ignoreChanges D) cloudFiles.maxFilesPerTrigger Answer: B Explanation: Setting cloudFiles.inferColumnTypes to true enables Auto Loader to detect and incorporate new columns. Question 25. Which of the following best describes a “gold-standard” dataset in Databricks? A) Raw data stored in the Bronze layer. B) A certified, business-ready table that has passed quality checks. C) Any Delta table that has a primary key defined. D) A dataset that is publicly shared via Databricks Marketplace. Answer: B Explanation: Gold-standard (or certified) datasets are curated, cleaned, and approved for production analytics.

A) Lineage graphs can be viewed from the Catalog Explorer. B) Lineage automatically records downstream dependencies for all tables. C) Lineage includes transformations performed inside notebooks only if they are registered as DLT pipelines. D) Lineage can be exported as a CSV file directly from the UI. Answer: D Explanation: Unity Catalog does not provide a direct CSV export of lineage graphs via the UI. Question 30. Which SQL function would you use to remove duplicate rows based on all columns in a Delta table? A) SELECT DISTINCT * FROM table; B) DELETE FROM table WHERE ROW_NUMBER() OVER (PARTITION BY * ) > 1; C) MERGE INTO table USING table AS src ON (condition) WHEN NOT MATCHED THEN INSERT *; D) OPTIMIZE table ZORDER BY *; Answer: A Explanation: SELECT DISTINCT returns unique rows across all columns, effectively removing duplicates. Question 31. What is the purpose of the ZORDER BY clause in an OPTIMIZE command? A) To physically reorder files to improve pruning on the specified columns. B) To sort query results alphabetically. C) To encrypt the selected columns. D) To create a materialized view. Answer: A Explanation: ZORDER BY clusters data on disk based on the given columns, enhancing data skipping during queries. Question 32. Which of the following best describes the role of Mosaic AI in Databricks? A) It provides vector search and similarity capabilities over large datasets.

B) It automates schema migrations. C) It is a visual dashboard builder. D) It replaces Delta Lake as the storage layer. Answer: A Explanation: Mosaic AI adds geospatial and vector search functions, enabling similarity queries on embeddings. Question 33. When creating a parameterized dashboard in Databricks, which object allows users to modify the query at runtime? A) Widget B) Notebook C) Table D) View Answer: A Explanation: Widgets (e.g., dropdowns, text boxes) expose parameters that can be referenced in SQL queries. Question 34. Which of the following is true about the Classic SQL Warehouse compared to Serverless? A) Classic warehouses require manual cluster provisioning and do not auto-scale to zero. B) Classic warehouses are billed per second. C) Classic warehouses support Photon while Serverless does not. D) Classic warehouses cannot access Unity Catalog objects. Answer: A Explanation: Classic warehouses are pre-provisioned clusters that stay up unless manually stopped, unlike Serverless which auto-scales. Question 35. Which command revokes all privileges from a role on a specific schema? A) REVOKE ALL PRIVILEGES ON SCHEMA analytics.sales FROM ROLE analyst; B) REVOKE ALL ON SCHEMA analytics.sales FROM ROLE analyst;

D) The lineage of the table. Answer: B Explanation: SHOW GRANTS lists the privileges that have been granted on the specified object. Question 39. Which of the following is a recommended way to handle PII in a Delta table? A) Store it in plain text and rely on network encryption. B) Apply column-level masking policies in Unity Catalog. C) Delete the columns entirely. D) Use OPTIMIZE to compress the data. Answer: B Explanation: Column-level masking lets you hide sensitive values from unauthorized users while keeping the data in place. **Question 40. In a Genie Space, what is the purpose of the “Instructions” section? ** A) To define the SQL syntax that Genie must follow. B) To give context and domain-specific guidance so the AI generates more accurate answers. C) To list all tables that are prohibited from being queried. D) To schedule periodic data refreshes. Answer: B Explanation: Instructions act as prompts that steer the AI’s behavior toward the intended domain knowledge. Question 41. Which of the following statements about the CACHE command in Databricks SQL is correct? A) It permanently stores the table on local SSDs. B) It creates an in-memory cache for the table that persists for the lifetime of the cluster. C) It encrypts the cached data.

D) It only works on external tables. Answer: B Explanation: CACHE TABLE loads the table into the cluster’s memory, improving query speed while the cluster is active. Question 42. Which window function would you use to assign a rank to rows based on sales amount, with ties receiving the same rank? A) ROW_NUMBER() OVER (ORDER BY sales DESC) B) RANK() OVER (ORDER BY sales DESC) C) DENSE_RANK() OVER (ORDER BY sales DESC) D) NTILE(4) OVER (ORDER BY sales DESC) Answer: B Explanation: RANK() provides ranking with gaps for ties, whereas DENSE_RANK() would not leave gaps. Question 43. What is the effect of setting spark.databricks.delta.autoCompact.enabled to true? A) Delta tables will automatically compact small files during write operations. B) It disables Z-ordering. C) It forces all tables to be stored in the Bronze layer. D) It enables automatic schema evolution. Answer: A Explanation: Auto-compaction reduces the number of small files, improving read performance. Question 44. Which of the following best describes “Federated Query” in Databricks? A) Running a query that accesses data in external databases via JDBC without moving the data. B) Merging multiple Delta tables into a single physical table. C) Exporting results to a data lake. D) Using dbt to orchestrate transformations.

Explanation: Delta Lake supports complex types like ARRAY, MAP, BINARY, but not native XML columns. Question 48. What does the EXPLAIN command show for a SQL statement in Databricks? A) The physical execution plan, including operators and estimated costs. B) The data lineage graph. C) The list of users who can run the query. D) The result set preview. Answer: A Explanation: EXPLAIN returns the query plan, helping users understand how Databricks will execute the statement. Question 49. Which of the following actions would you take to reduce shuffle overhead in a large join? A) Increase the number of partitions on both tables. B) Use broadcast hint on the smaller table. C) Disable caching on both tables. D) Set spark.sql.autoBroadcastJoinThreshold to 0. Answer: B Explanation: Broadcasting the smaller table avoids a shuffle by sending its data to all executors. Question 50. In Unity Catalog, what is the effect of assigning a tag sensitivity=high to a table? A) It automatically encrypts the table. B) It enables data discovery tools to surface the table as high-sensitivity. C) It revokes all SELECT privileges. D) It moves the table to a separate storage account. Answer: B Explanation: Tags are metadata; assigning sensitivity=high helps governance and discovery but does not enforce technical controls by itself.

Question 51. Which of the following best describes the purpose of “Liquid Clustering” compared to traditional partitioning? A) It replaces partitions with a dynamic, query-aware clustering that adapts over time. B) It stores data in a liquid-state format for faster I/O. C) It is a feature exclusive to GPU clusters. D) It automatically encrypts clustered columns. Answer: A Explanation: Liquid clustering continuously reorganizes data based on query patterns, reducing the need for static partitions. Question 52. Which command would you use to list all tables that a specific user has SELECT access to in a given catalog? A) SHOW GRANTS FOR USER alice; B) SHOW TABLES IN CATALOG analytics; C) LIST PRIVILEGES FOR USER alice; D) DESCRIBE GRANTS USER alice; Answer: A Explanation: SHOW GRANTS FOR USER displays the privileges granted to that user, including SELECT on tables. Question 53. In a Databricks notebook, which magic command switches the interpreter to SQL mode? A) %sql B) %%sql C) !sql D) #sql Answer: A Explanation: %sql tells the notebook to treat subsequent lines as SQL statements.

A) The policy is evaluated once per query, not per row. B) Users can override the policy with SET commands. C) The policy can reference session variables such as current_user(). D) It only works on external tables. Answer: C Explanation: RLS policies can use functions like current_user() to filter rows dynamically per session. Question 58. Which of the following best describes the function of the “Data Intelligence Engine” in Databricks? A) It powers the Photon execution engine for SQL. B) It provides automated lineage, impact analysis, and metadata enrichment across the platform. C) It manages cluster autoscaling policies. D) It handles secret management for notebooks. Answer: B Explanation: The Data Intelligence Engine centralizes metadata, lineage, and impact analysis for better governance. Question 59. Which SQL clause would you use to rename a column in a view without altering the underlying table? A) ALTER VIEW … RENAME COLUMN … B) CREATE OR REPLACE VIEW … AS SELECT col AS new_name … C) ALTER TABLE … RENAME COLUMN … D) MODIFY VIEW … CHANGE COLUMN … Answer: B Explanation: Re-creating the view with a new SELECT alias changes the column name at the view level. Question 60. Which of the following is a valid way to create a parameter in a Databricks dashboard? A) SET @region = 'US' in the SQL query.

B) Adding a widget via the UI and referencing ${region} in the query. C) Defining a variable in a notebook cell. D) Using PARAMETER(region) function. Answer: B Explanation: Dashboard widgets expose parameters that can be referenced with $ {parameter_name} in SQL. Question 61. Which of the following is true about the OPTIMIZE command with ZORDER BY on a high-cardinality column? A) It always improves query performance regardless of query patterns. B) It may increase storage cost due to additional file metadata. C) It disables automatic compaction. D) It converts the table to a materialized view. Answer: B Explanation: Z-ordering on high-cardinality columns can create many small files, potentially increasing storage overhead. Question 62. In Databricks, what does the “Partner Connect” feature primarily facilitate? A) Direct connection to third-party SaaS tools for data ingestion and transformation. B) Automatic creation of user groups. C) Real-time streaming of logs to external monitoring services. D) Deploying custom machine learning models. Answer: A Explanation: Partner Connect provides one-click integrations with tools like Fivetran, dbt, and Looker. Question 63. Which of the following statements about “Gold” tables in the Medallion Architecture is correct? A) They contain raw, unprocessed data. B) They are the final, business-ready datasets used for reporting and analytics. C) They are automatically generated by Auto Loader.