Practice table::
Order ID | Customer Name | Order Date | Total Cost | Status |
---|---|---|---|---|
1 | Jane Doe | 1/1/2022 | $100.00 | Shipped |
2 | Jane Doe | 1/2/2022 | $75.00 | Pending |
3 | Mark Smith | 1/3/2022 | $50.00 | Shipped |
4 | Emily Gray | 1/4/2022 | $200.00 | Shipped |
5 | Tom Hill | 1/5/2022 | $150.00 | Pending |
6 | Sarah Jones | 1/6/2022 | $25.00 | Shipped |
7 | Mike Brown | 1/7/2022 | $300.00 | Pending |
8 | Anna Green | 1/8/2022 | $100.00 | Shipped |
9 | David White | 1/9/2022 | $50.00 | Pending |
10 | Karen Black | 2/10/2022 | $175.00 | Shipped |
Questions to answer:
- Retrieve all orders that have been shipped.
- Retrieve all orders that are still pending.
- Retrieve all orders that have a total cost of $100 or more.
- Retrieve all orders that were placed in January 2022.
- Retrieve all orders that were placed by customers whose name starts with "J".
- Retrieve all orders that were placed by customers whose name contains the letter "a".
- Retrieve the total cost of all orders that have been shipped.
- Retrieve the average cost of all orders that are still pending.
- Retrieve the earliest order date for each customer.
- Retrieve the customer who has placed the most orders.
Top comments (0)