SQL Practice Logo

SQLPractice Online

Level 2 - JuniorQuery-Based Questions

Top 2 Products by Units Sold

Write SQL to return product_id, product_name, and total_units for the top 2 products by units sold.

Schema Context

products(id, name), order_items(id, order_id, product_id, quantity)