Sample questions
Question 1:
Which of the following code snippets creates a view in Spark SQL that will replace existing views if already present?
- dataFrame.createOrReplaceTempView()
- dataFrame.createTempView()
- dataFrame.createTableView()
- dataFrame.createOrReplaceTableView()
- dataDF.write.path(filePath)
Question 2:
Which function do we use to join two DataFrames together?
- DataFrame.filter()
- DataFrame.distinct()
- DataFrame.intersect()
- DataFrame.join()
- DataFrame.count()
Answers
- A
- D
 
                                             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
             
     
         
                 
                 
                 
                 
                 
                 
                 
                 
                