How can I SELECT rows with MAX(Column value), PARTITION by another column in MYSQL?

My table is: id home datetime player resource 1 10 04/03/2009 john 399 2 11 04/03/2009 juliet 244 5 12 04/03/2009 borat 555 3 10 03/03/2009 john 300 4 11 03/03/2009 juliet 200 6 12 03/03/2009 borat 500 7 13 24/12/2008 borat 600 8 13 01/01/2009 borat 700 I need to select each distinct home … Read more

SQL select only rows with max value on a column [duplicate]

Want to improve this post? Provide detailed answers to this question, including citations and an explanation of why your answer is correct. without enough detail may be edited or deleted. This question already has answers here: Retrieving the last record in each group – MySQL (32 answers) Closed 3 years ago. I have this table … Read more