Skip to main content

Exam 3: Filtering Techniques

Difficulty: Beginner+

Topics covered: IN, NOT IN, BETWEEN, LIKE, IS NULL

Each question shows the target output. Write a SQL query that produces exactly those columns and rows.


Question 1

Retrieve all columns from products in the 'Electronics' or 'Furniture' category. Use IN.

⌘ / Ctrl + Enter to run

Question 2

Retrieve all columns from orders where total_amount is between 50 and 400 (inclusive).

⌘ / Ctrl + Enter to run

Question 3

Retrieve all columns from customers whose name starts with the letter 'C'.

⌘ / Ctrl + Enter to run

Question 4

Retrieve the name and city of customers whose city starts with 'N'.

⌘ / Ctrl + Enter to run

Question 5

Retrieve the order_id, customer_id, and status of orders not placed by customers 1 or 2. Use NOT IN.

⌘ / Ctrl + Enter to run

Question 6

Retrieve customer_id, name, and city for any customer whose city has not been recorded.

⌘ / Ctrl + Enter to run
Donate to this project