Advertisement
aloushi234
Nov 7th, 2023
37
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. нужно было использовать оператор MAX:
  2.  
  3. SELECT billing_city
  4. FROM invoice
  5. WHERE total >
  6.     (SELECT MAX(total)
  7.      FROM invoice
  8.      WHERE EXTRACT(YEAR FROM CAST(invoice_date AS DATE)) = 2009)
  9. GROUP BY billing_city;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement