This is a verified interview question from Quickshell-backend. Candidates reporting seeing this problem in recent Online Assessments (OAs) and onsite rounds. Mastering "Customers with Unshipped Orders" covers key patterns like Other.
"### Problem You are given two tables: orders and shipments. The orders table contains customer purchase orders. The shipments table logs shipments dispatched for these orders. Each order is expected to have one shipment if fulfilled. Write a query to find all customers who have placed at least one order that has not yet been shipped. Return the customer's name and the count of such unshipped orders. ### Table Structure #### Table Name: orders | Column | Type | Description | | --- | --- | --- | | order_id | INT | Unique 6-digit order ID | | customer_id | VARCHAR(50) | Name of customer | | product_id | VARCHAR(50) | Product purchased | #### Table Name: shipments | Column | Type | Description | | order_id | INT | FK for orders.order_id | | shipped_date | DATE | Date when order was shipped | ### Answer Structure The answer should include the customer's name and the count of unshipped orders."
Join thousands of developers practicing for Quickshell-backend.