Given the example table below, how can I retrieve the high and low range of the entire group using pure MySQL? Is it possible?
Table:
string low high
=====================
abc 1 10
abc 11 20
def 2 5
def 3 6
Basic Query: (Obviously this doesn’t work, but what would?)
SELECT * from `table` GROUP BY `string`;
I want to get here, via MySQL if possible:
string low high
=====================
abc 1 20
def 2 6
It’s as simple as: