MEDIUMVerified Real Interview• Logistics Operations Analyst
Prime 24-Hour Guaranteed Delivery SLA Breaches
Verified Source:Public Candidate Interview Report
Amazon Logistics monitors fulfillment performance against Prime 24-hour delivery SLAs.
Write a SQL query to identify all orders where actual delivery time exceeded order placement time by more than 24.0 hours. Calculate:
order_idcustomer_idhours_to_deliver(rounded to 1 decimal place)breach_severitycategorizing delay:- 'Moderate Breach' if between 24.1 and 36.0 hours
- 'Severe Breach' if greater than 36.0 hours
Order by hours_to_deliver descending.
Tables:
fulfillment_orders(order_idINT,customer_idINT,ordered_atTIMESTAMP,delivered_atTIMESTAMP)
Execution Sandbox:
Your query executes inside an isolated in-memory PostgreSQL engine (PGlite WebAssembly). You have full access to standard PostgreSQL aggregations, window functions, and CTEs.
Standard SQL (ANSI)|Ln 1, Col 1(7 lines, 126 chars)
Tab Indent⌘↵ Run Query
Ready to execute. Press Run (⌘+Enter)
Write your query and click “Run” or press ⌘+Enter to inspect output.