📖 Story
Swiggy · Kitchen Cancellation Rates
Wednesday afternoon at Swiggy's Kitchen Health team. swiggy_kitchen_orders logs every order placed at a dark kitchen along with its order_status. A kitchen gets flagged for review when more than 20% of its resolved orders end up cancelled. Some rows have order_status = NULL — the order is still out for delivery or being prepared, with no final outcome yet, so it hasn't actually resolved as either a delivery or a cancellation. The team wants a clean list of every kitchen currently over the 20% cancellation threshold, and an in-transit order must not be counted as if it were a completed, non-cancelled order.