Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close
Introduction
The COALESCE() function
The GREATEST() & LEAST() functions
The NULLIF() function
Summary
17. Exercise 2

Instruction

That's great! Let's see how you fare with Exercise 2.

Exercise

For each product, show three columns:

  • id
  • product_type – the type of the product. If there is no product type, show 'unknown type'.
  • new_launch_date – the launch date. If the launch_date is NULL, show the current date instead (use CURRENT_DATE).

Order the results by new_launch_date, with the oldest dates appearing first.