Loading exercise…
Loading exercise…
Exercises are built for a keyboard. Read the task here, then open this page on a laptop to solve it.
CASE WHEN. CASE builds a new column from rules. SQL checks the WHEN lines from the top and uses the first one that is true; ELSE catches everything else. Finish with END and name the column with AS.
select customer_name, case when segment = 'Enterprise' then 'Key account' else 'Standard account' end as account_type from customers
The catalog team wants every product labelled Budget, Standard or Premium for the new price list.
Return product_name, list_price and price_band for all products: 'Budget' when list_price is below 10, 'Standard' from 10 up to but not including 25, and 'Premium' from 25 up.
Loading the Brightline dataset…
Language
Full plan
SQL ✓ · Excel and Power BI also included
Cancel anytime · 14-day full refund · Secure payment by Stripe