!613
SELECT divId, divName, teamId, teamName, teamAbbreviation, teamCapId, teamCapIdCo,
SUM(scoreWon) AS sumWon, SUM(scoreLoss) AS sumLoss,SUM(scorePlayed) AS sumPlayed, SUM(scoreTieBreak) AS sumTieBreak FROM `scoreLog`
LEFT JOIN `teamLog` ON `scoreTeamId` = `teamId`
LEFT JOIN `divisionLog` ON `teamDivId` = `divId`
WHERE `divId`=4 AND `scoreHide` = 'no' AND `scoreStatus` = 'played'
GROUP BY teamId,divId ORDER BY sumWon DESC, sumLoss ASC,`sumTieBreak` ASC,teamName
Standings !616
No results to report
SELECT divId, divName, teamId, teamName, teamAbbreviation, teamCapId, teamCapIdCo,
SUM(scoreWon) AS sumWon, SUM(scoreLoss) AS sumLoss,SUM(scorePlayed) AS sumPlayed, SUM(scoreTieBreak) AS sumTieBreak FROM `scoreLog`
LEFT JOIN `teamLog` ON `scoreTeamId` = `teamId`
LEFT JOIN `divisionLog` ON `teamDivId` = `divId`
WHERE `divId`=4 AND `scoreHide` = 'no' AND `scoreStatus` = 'played'
GROUP BY teamId,divId ORDER BY sumWon DESC, sumLoss ASC,`sumTieBreak` ASC,teamName