Save up to $499! Grab all Python courses for $49 or all online courses we’ve ever launched for only $169. Only Feb 11-16. Happy Valentine's!
Get to know tables
OVER()
Computations with OVER()
Aggregate functions with OVER()
OVER() and WHERE
Summary
16. Exercise 2

Instruction

Great! Now, the more difficult exercise!

Exercise

For each purchase, show its:

  • id,
  • the name of the department,
  • the item,
  • the price,
  • the minimum price from all the rows in the query result,
  • the difference between the price and the minimum price.