SELECT COUNT(DISTINCT author_fname) FROM books;
SELECT title FROM books WHERE title LIKE '%the%';
SELECT author_lname, COUNT(*) FROM books GROUP BY author_lname;
SELECT released_year, COUNT(*) FROM books GROUP BY released_year;
SELECT MIN(released_year) FROM books;
SELECT MAX(pages) FROM books;
SUB쿼리
SELECT * FROM books
WHERE pages = (SELECT Min(pages)
FROM books);
가장 적은 페이지를 가진 책의 이름과 페이지 가져오기
SELECT title, pages FROM books
ORDER BY pages ASC LIMIT 1;
SUM: 합 구할때
SELECT SUM(pages) FROM books;
AVG: 평균 구할때
SELECT AVG(pages) FROM books;