DP-900 · Question #140
DP-900 Question #140: Real Exam Question with Answer & Explanation
To calculate the average sales amount per day, you need SELECT to specify the columns and the AVG() aggregate function, and GROUP BY to group the results by the day/date column so the average is computed for each individual day rather than across all rows. The SELECT clause defin
Question
Drag and Drop Question You have a table named Sales that contains the following data. You need to query the table to return the average sales amount day. The output must produce the following results How should you complete the query? To answer, drag the appropriate values to the correct targets. Each value may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content. NOTE: Each correct selection is worth one point. Answer:
Explanation
To calculate the average sales amount per day, you need SELECT to specify the columns and the AVG() aggregate function, and GROUP BY to group the results by the day/date column so the average is computed for each individual day rather than across all rows. The SELECT clause defines what data to retrieve and applies the aggregate function, while GROUP BY partitions the result set into groups (one per day) so AVG() operates on each day's records independently.
Topics
Community Discussion
No community discussion yet for this question.