QuestionQ9

Executing queries using Databricks SQL and Databricks SQL Warehouses

A data analyst needs the following output:

Question Image

Which statement produces this output?

  • A
  • B
  • C
  • D
Explanation

COUNT(order_id) calculates the number of orders for each customer, GROUP BY customer_name creates one result row per customer, and AS number_of_orders supplies the requested output-column name. The join matches each order to its customer through customer_id.

Community Discussion

No comments yet. Be the first to start the discussion!