Which of the following code blocks reads all CSV files in directory filePath into a single DataFrame, with column names defined in the CSV file headers?
Content of directory filePath:
1._SUCCESS
2._committed_2754546451699747124
3._started_2754546451699747124
4.part-00000-tid-2754546451699747124-10eb85bf-8d91-4dd0-b60b-2f3c02eeecaa-298-1- c000.csv.gz
5.part-00001-tid-2754546451699747124-10eb85bf-8d91-4dd0-b60b-2f3c02eeecaa-299-1- c000.csv.gz
6.part-00002-tid-2754546451699747124-10eb85bf-8d91-4dd0-b60b-2f3c02eeecaa-300-1- c000.csv.gz
7.part-00003-tid-2754546451699747124-10eb85bf-8d91-4dd0-b60b-2f3c02eeecaa-301-1- c000.csv.gz
spark.option("header",True).csv(filePath)
A. spark.read.format("csv").option("header",True).option("compression","zip").load(filePath)Which of the following code blocks reads JSON file imports.json into a DataFrame?
A. spark.read().mode("json").path("/FileStore/imports.json")The code block displayed below contains an error. The code block should return the average of rows in column value grouped by unique storeId. Find the error.
Code block:
transactionsDf.agg("storeId").avg("value")
A. Instead of avg("value"), avg(col("value")) should be used.The code block shown below should show information about the data type that column storeId of DataFrame transactionsDf contains. Choose the answer that correctly fills the blanks in the code block to accomplish this.
Code block: transactionsDf.__1__(__2__).__3__
A. 1. select 2. "storeId" 3. print_schema()Which of the following statements about DAGs is correct?
A. DAGs help direct how Spark executors process tasks, but are a limitation to the proper execution of a query when an executor fails.Which of the following statements about executors is correct, assuming that one can consider each of the JVMs working as executors as a pool of task execution slots?
A. Slot is another name for executor.Which of the following code blocks displays various aggregated statistics of all columns in DataFrame transactionsDf, including the standard deviation and minimum of values in each column?
A. transactionsDf.summary()The code block displayed below contains an error. The code block should return a DataFrame where all entries in column supplier contain the letter combination et in this order. Find the error.
Code block:
itemsDf.filter(Column('supplier').isin('et'))
A. The Column operator should be replaced by the col operator and instead of isin, contains should be used.Which of the following describes slots?
A. Slots are dynamically created and destroyed in accordance with an executor's workload.Which of the following statements about lazy evaluation is incorrect?
A. Predicate pushdown is a feature resulting from lazy evaluation.Nowadays, the certification exams become more and more important and required by more and more enterprises when applying for a job. But how to prepare for the exam effectively? How to prepare for the exam in a short time with less efforts? How to get a ideal result and how to find the most reliable resources? Here on Vcedump.com, you will find all the answers. Vcedump.com provide not only Databricks exam questions, answers and explanations but also complete assistance on your exam preparation and certification application. If you are confused on your DATABRICKS-CERTIFIED-ASSOCIATE-DEVELOPER-FOR-APACHE-SPARK exam preparations and Databricks certification application, do not hesitate to visit our Vcedump.com to find your solutions here.