Practice · easy · dataset: ecom
Pending or refunded orders, excluding partners
Support wants a follow-up list of orders that are either pending or refunded, but not placed
through the partner channel.
Return order_id, status, channel, and order_date. Sort by order_date ascending, then by
order_id ascending.
Tables available
| Table | Columns |
|---|---|
orders |
order_id, customer_id, order_date, status, channel |
The status condition and the channel exclusion must both hold. paid, shipped, and cancelled
orders are outside the request.
⌘/Ctrl + Enter to grade
Write a query, then grade it.
Hints
Try it first. Reveal a hint only when you are stuck.