Search Header Logo

SQL Where,GB,Having,OB Part 3

Authored by Nidhi Singh

Computers

5th Grade

Used 2+ times

SQL Where,GB,Having,OB Part 3
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

8 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Media Image

What does the following SQL query do?

Shows all shipped orders sorted by the date they were placed.

Shows all orders sorted by status.

Shows all orders, including canceled ones.

2.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Media Image

What does the following SQL query do?

Show all products with prices under $20.

Show products with an average price of $20 or more.

Show products with an average price below $20.

3.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which SQL statement will return all orders placed by customers from "New York"?

SELECT * FROM Orders ORDER BY City;

SELECT * FROM Orders WHERE City = 'New York';

SELECT * FROM Orders HAVING City = 'New York';

4.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Media Image

What will the following SQL query return?

Departments with 3 or more employees.

All employees sorted by department.

Departments with fewer than 3 employees.

5.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

If you want to group students by their grades and find out how many students are in each grade, which clause do you need?

WHERE

HAVING

ORDER BY

GROUP BY

6.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

How can you find the maximum price of items in a store?

SELECT MAX(Price) FROM Items;

SELECT * FROM Items ORDER BY Price;

SELECT Price FROM Items WHERE MAX(Price);

7.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

If you want to see all customers who made purchases in 2024, which SQL statement would you use?

SELECT * FROM Customers WHERE PurchaseYear = 2024;

SELECT * FROM Customers WHERE YEAR(PurchaseDate) = 2024;

SELECT * FROM Customers ORDER BY PurchaseDate;

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?