Free CERTIFIED-ASSOCIATE-DEVELOPER-FOR-APACHE-SPARK Databricks CERTIFIED-ASSOCIATE-DEVELOPER-FOR-APACHE-SPARK Practice Test Question

Loading demo links...

Showing 19–21 of 23 questions

Question 19 (Topic 1)

The code block shown below should read a parquet at the file path filePath into a DataFrame. Choose the response that correctly fills in the numbered blanks within the code block to complete this task. Code block: __1__.__2__.__3__(__4__)

Select an option, then click Submit answer.

  • 1.spark 2. read() 3. parquet 4. filePath
  • 1. spark 2. read() 3. load 4. filePath
  • 1. spark 2. read 3. load 4. filePath, source = "parquet"
  • 1. storesDF 2. read() 3. load 4. filePath
  • 1. spark 2. read 3. load 4. filePath
Question 20 (Topic 1)

The code block shown below contains an error. The code block is intended to return a new DataFrame where column productCategories only has one word per row, resulting in a DataFrame with many more rows than DataFrame storesDF. Identify the error and how to fix it. A sample of storesDF is displayed below: storesDF.withColumn("productCategories", split(col("productCategories")))

Select an option, then click Submit answer.

  • The split() operation does not accomplish the requested task in the way that it is used. It should be used provided an alias.
  • The split() operation does not accomplish the requested task. The broadcast() operation should be used instead.
  • The split() operation does not accomplish the requested task in the way that it is used. It should be used as a column object method instead.
  • The split() operation does not accomplish the requested task. The explode() operation should be used instead.
  • The split() operation does not accomplish the requested task. The array_distinct() operation should be used instead.
Question 21 (Topic 1)

If Spark is running in cluster mode, which of the following statements about nodes is incorrect?

Select an option, then click Submit answer.

  • The Spark driver runs in its own node without any executors.
  • Each executor is a running processing engine inside of a worker node.
  • There may be more executors than total nodes or more total nodes than executors.
  • There is always more than one node.
  • There is a single node that contains the Spark driver and the executors.