~/ learn/ postgresql/ cards/ Subqueries & CTEs
1 of 10

Find the titles and prices of books priced above the overall average price.

Find the titles and prices of books priced above the overall average price.

Answer

SELECT title, price FROM books WHERE price > (SELECT AVG(price) FROM books);

space flip · ← → navigate · esc to exit
NORMAL ~/memra/library/4475ec21-caf0-4332-98d2-9ce971aac276/flashcard utf-8 LF