CERTIFIED-ASSOCIATE-DEVELOPER-FOR-APACHE-SPARK Databricks Certified Associate Developer for Apache Spark
Study 220 CERTIFIED-ASSOCIATE-DEVELOPER-FOR-APACHE-SPARK Databricks Certified Associate Developer for Apache Spark practice questions with explanations. 22 of them are free to try, no sign-up needed.
Buy to unlock all questions, full reading mode and PDFs.
About this question bank
Questions
220 in total
Free to try
22 questions (no sign-up)
Exam domains
6 domains
Price
JPY 1,500 (≈ US$10; shown in your local currency at checkout) · one-time payment · 3 months
PDF
Japanese–English · Chinese–English · Korean–English · English (for buyers)
Data version
2026-12
About this exam
Databricks Certified Associate Developer for Apache Spark, offered by Databricks, validates foundational skills in developing with the Apache Spark DataFrame API. It covers Spark architecture basics (driver, executors, partitions and so on) and using DataFrames to select, transform, aggregate and join data, read and write common formats, and work with Spark SQL.
Try a sample question
This is an original sample question written by itmoshi based on the exam objectives.
The df in the exhibit has 400 partitions, but after the filter the data is small, so writing it as is would create many tiny files. You want df reduced to 8 partitions just before the write, without triggering a full shuffle of the data. Which code is most appropriate for writing it as Parquet?
Exhibit
df = (spark.read.parquet("/Volumes/main/raw/files/events")
.filter("event_type = 'purchase'"))
df.rdd.getNumPartitions() # -> 400
# After the filter, the data is small and every partition holds only a few rows.
Answer:D coalesce reduces the number of partitions without a shuffle.
Why it is correct
Each partition writes its own file(s), so reducing the partition count also brings the output down to around 8 files. coalesce(8) is a narrow transformation that merges existing partitions into 8 without redistributing data across the cluster, so no shuffle occurs. It works this way only when reducing the number of partitions.
The other options
✗ A repartition(8) also yields 8 partitions, but it shuffles all the data to spread it evenly, which breaks the no-shuffle requirement. Use it to fix skewed partitions or to increase the partition count.
✗ B spark.sql.shuffle.partitions sets the number of partitions produced by shuffles such as groupBy or join; this df has no shuffle, so it stays at 400. Use it to tune partition counts after aggregations or joins.
✗ C maxRecordsPerFile caps records per file; it can split a large partition into several files but never merges small ones. Use it to keep individual files from growing too large.
Key takeaway
Fewer partitions, no shuffle → coalesce. More partitions or fixing skew (shuffle) → repartition. Partitions after a shuffle → spark.sql.shuffle.partitions. Cap per file → maxRecordsPerFile.