Loading...

Regional Order Summary

A medium SQL interview practice problem on DataDriven. Write and execute real sql code with instant grading.

Domain
SQL
Difficulty
medium

Problem

Drop orders rows where region is NULL. Per region, return region, COUNT(order_id) as order_count, and SUM(profit) as total_profit. Keep regions with at least 5 orders. Sort from highest total_profit to lowest, breaking ties alphabetically by region.

Practice This Problem

Solve this SQL problem with real code execution. DataDriven runs your SQL queries against a real database and grades it automatically.