Loading...
MySQL 9.5 Reference Manual 9.5의 5.6.3 Maximum of Column per Group의 한국어 번역본입니다.
아래의 경우에 피드백에서 신고해주신다면 반영하겠습니다.
감사합니다 :)
작업: article별로 가장 높은 price를 찾습니다.
1SELECT article, MAX(price) AS price 2FROM shop 3GROUP BY article 4ORDER BY article; 5 6+---------+-------+ 7| article | price | 8+---------+-------+ 9| 0001 | 3.99 | 10| 0002 | 10.99 | 11| 0003 | 1.69 | 12| 0004 | 19.95 | 13+---------+-------+
5.6.2 The Row Holding the Maximum of a Certain Column
5.6.4 The Rows Holding the Group-wise Maximum of a Certain Column