SELECT
max(nameFirst),
max(nameLast),
replace(batting.yearID,',',''),
sum(batting.HR) AS seasonHR,
IF(
max(name) == min(name),
max(name),
concat(min(name),'/',max(name))
)
FROM batting INNER JOIN people
ON batting.playerID = people.playerID
INNER JOIN teams
ON batting.teamID = teams.teamID AND batting.yearID = teams.yearID
GROUP BY batting.playerID, batting.yearID
HAVING seasonHR >= 50
ORDER BY seasonHR DESC