SQL Practice Logo

SQLPractice Online

Scenario SQL Question

Calculate Discount Based on Order Quantity

Build mastery in Case Statements with this scenario-based SQL challenge and live execution support.

Problem Statement

Apply discounts to orders based on quantity: 5% discount if quantity >= 10, 10% if quantity >= 20, 15% if quantity >= 50. Return order_id, quantity, price, and discounted price.

Relevant Tables

orders

SQL Concepts Used in This Scenario

Strengthen your understanding with these targeted learning topics: