
Let's practice! - Aggregating Data

Quiz
•
Specialty
•
University
•
Hard
Thuan Tran
FREE Resource
6 questions
Show all answers
1.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Obtain a grand total of the demand_loss_mw column by using the SUM function, and alias the result as MRO_demand_loss.
SELECT .......... AS .......... FROM grid;
2.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Fill in the blank
Only retrieve rows WHERE demand_loss_mw is not NULL and nerc_region is 'MRO'.
SELECT SUM(demand_loss_mw) AS MRO_demand_loss FROM grid
WHERE ______;
3.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Return the COUNT of the grid_id column, aliasing the result as grid_total.
SELECT ........ AS ........ FROM grid;
4.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Make the count more meaningful by restricting it to records where the nerc_region is 'RFC'. Name the result RFC_count.
SELECT COUNT(grid_id) AS .......... FROM grid WHERE ..........;
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Find the minimum value from the affected_customers column, but only for rows where demand_loss_mw has a value. Name the result min_affected_customers.
SELECT
MIN(affected_customers) AS min_affected_customers
FROM grid
WHERE demand_loss_mw IS NOT NULL;
SELECT
MIN(affected_customers) AS min_affected_customers
FROM grid
WHERE demand_loss_mw NOT NULL;
SELECT
MIN(affected_customers) AS min_affected_customers
FROM grid
WHERE demand_loss_mw IS NULL;
SELECT
MIN(affected_customers) AS min_affected_customers
FROM grid
WHERE demand_loss_mw == NULL;
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Find the maximum value from the affected_customers column, but only for rows where demand_loss_mw has a value. Name the result max_affected_customers.
SELECT
MAX(affected_customers) AS max_affected_customers
FROM grid
WHERE demand_loss_mw IS NULL;
SELECT
MAX(affected_customers) AS max_affected_customers
FROM grid
WHERE demand_loss_mw NOT NULL;
SELECT
MAX(affected_customers) AS max_affected_customers
FROM grid
WHERE demand_loss_mw IS NOT NULL;
SELECT
MAX(affected_customers) AS max_affected_customers
FROM grid
WHERE demand_loss_mw == NULL;
Similar Resources on Wayground
10 questions
Know your ITL!

Quiz
•
University
10 questions
MUET Lower Six ULTIMATE QUIZ (RMO Edition)

Quiz
•
University - Professi...
7 questions
HFTSK Day 4 Recap

Quiz
•
12th Grade - Professi...
11 questions
RCOA 101

Quiz
•
University
10 questions
Halal Supply Chain_UIS

Quiz
•
University
10 questions
CMSD 100 Chapter 1

Quiz
•
University
10 questions
Academy

Quiz
•
KG - University
10 questions
Cellular Adaptation

Quiz
•
University
Popular Resources on Wayground
15 questions
Hersheys' Travels Quiz (AM)

Quiz
•
6th - 8th Grade
20 questions
PBIS-HGMS

Quiz
•
6th - 8th Grade
30 questions
Lufkin Road Middle School Student Handbook & Policies Assessment

Quiz
•
7th Grade
20 questions
Multiplication Facts

Quiz
•
3rd Grade
17 questions
MIXED Factoring Review

Quiz
•
KG - University
10 questions
Laws of Exponents

Quiz
•
9th Grade
10 questions
Characterization

Quiz
•
3rd - 7th Grade
10 questions
Multiply Fractions

Quiz
•
6th Grade