Free Certified Data Engineer Associate Exam Braindumps
Certified Data Engineer Associate Questions 81–88 (page: 12)

Updated On: 7-Apr-2026

Which command will return the number of null values in the member_id column?

  1. SELECT count(member_id) FROM my_table;
  2. SELECT count(member_id) - count_null(member_id) FROM my_table;
  3. SELECT count_if(member_id IS NULL) FROM my_table;
  4. SELECT null(member_id) FROM my_table;

Answer(s): C

Explanation:

The count_if(condition) function counts the number of rows in a table that satisfy a specific condition. In this case, count_if(member_id IS NULL) counts the rows where the member_id column is NULL, returning the desired count of null values.



Which benefit is provided by the array functions from Spark SQL?

  1. An ability to work with data in a variety of types at once
  2. An ability to work with data within certain partitions and windows
  3. An ability to work with time-related data in specified intervals
  4. An ability to work with complex, nested data ingested from JSON files

Answer(s): D

Explanation:

Spark SQL's array functions provide powerful tools to work with complex and nested data structures, such as arrays and maps, often encountered in JSON files or semi-structured data formats. These functions allow users
to:
Access elements within arrays.

Transform arrays by applying operations like filtering, sorting, or aggregation.

Flatten nested arrays for easier analysis.



A data engineer is working with two tables. Each of these tables is displayed below in its entirety.



The data engineer runs the following query to join these tables together:



Which of the following will be returned by the above query?





Answer(s): C

Explanation:

The query uses a LEFT JOIN, which includes all rows from the left table (sales) and matches them with rows from the right table (favorite_stores) based on the condition sales.customer_id = favorite_stores.customer_id. If there is no match in the right table, the resulting columns from the right table (store_id) will be NULL.
From sales:

a1 matches with a1 in favorite_stores, so the result includes a1 with store_id = s1.

a3 has no match in favorite_stores, so store_id = NULL.

a4 matches with a4 in favorite_stores, so the result includes a4 with store_id = s2.

Thus, the result will have:
a1 with spend = 28.94 and store_id = s1

a3 with spend = 874.12 and store_id = NULL

a4 with spend = 8.99 and store_id = s2



Which SQL code snippet will correctly demonstrate a Data Definition Language (DDL) operation used to create a table?

  1. CREATE TABLE employees (
    id INT,
    name STRING
    );
  2. DROP TABLE employees;
  3. ALTER TABLE employees ADD COLUMN salary DECIMAL(10,2);
  4. INSERT INTO employees (id, name) VALUES (1 'Alice');

Answer(s): A

Explanation:

CREATE TABLE employees (...) is a Data Definition Language (DDL) operation that defines a new table and its schema.



What are the transformations typically included in building the Bronze layer?

  1. Include columns Load date/time, process ID
  2. Business rules and transformations
  3. Perform extensive data cleansing
  4. Aggregate data from multiple sources

Answer(s): A

Explanation:

The Bronze layer stores raw ingested data with minimal transformations, typically adding metadata columns such as load date/time and process ID for traceability and auditing.



A global retail company sells products across multiple categories (e.g., Electronics, Clothing) and regions (e.g., North, South, East, West). The sales team has provided the data engineer with a PySpark dataframe named sales_df as below and the team wants the data engineer to analyze the sales data to help them make strategic decisions.



Calculate the total sales amount for each product category and store the results in a new dataframe called category_sales.

What will generate the expected result of category_sales?

  1. category_sales = sales_df.groupBy("category").agg(sum("sales_amount").alias ("total_sales_amount"))
  2. category_sales = sales_df.sum("sales_amount").groupBy("category").alias ("total_sales_amount"))
  3. category_sales = sales_df.agg(sum("sales_amount").groupBy("category").alias ("total_sales_amount"))
  4. category_sales = sales_df.groupBy("region").agg(sum("sales_amount").alias
    ("total_sales_amount"))

Answer(s): A

Explanation:

The correct approach is to group by the product category and then aggregate the sum of sales_amount, aliasing it as total_sales_amount. This produces the expected totals: 500 for Electronics and 900 for Clothing.



A data engineer has a DataFrame named sales_df containing columns for "region" and "sales_amount". They need to calculate the total sales for each unique region and rename the resulting sum column to "total_sales_amount".

Which of the following code snippets will produce the correct result?

  1. region_sales = sales_df.groupBy("category").sum("sales_amount").alias ("total_sales_amount")
  2. region_sales = sales_df.groupBy("region").agg(sum("sales_amount").alias ("total_sales_amount"))
  3. region_sales = sales_df.sum("sales_amount").groupBy("region").alias ("total_sales_amount")
  4. region_sales = sales_df.agg(sum("sales_amount").groupBy("region").alias ("total_sales_amount"))

Answer(s): B

Explanation:

To calculate total sales per region, you group by "region" and apply an aggregation using sum("sales_amount"), aliasing it as total_sales_amount. This produces the expected result of 250 (North), 500 (South), 250 (East), and 400 (West).



In a Medallion architecture, which layer is responsible for storing raw ingested data from source systems—such as historical event data from Kafka—in its original format to ensure data lineage and low-cost history preservation?

  1. Gold
  2. Silver
  3. Bronze
  4. Raw layer

Answer(s): C

Explanation:

In the Medallion architecture, the Bronze layer stores raw ingested data, including historical event data from Kafka. This approach preserves the full history at lower cost while allowing further refinement into Silver and Gold layers.



Viewing page 12 of 30
Viewing questions 89 - 96 out of 280 questions


Post your Comments and Discuss Databricks Certified Data Engineer Associate exam prep with other Community members:

AI Tutor AI Tutor 👋 I’m here to help!