I'm a total newbie at sabermetrics, so I am just playing around with a mysql database with the Baseball databank installed. I was reading something about payrolls and wanted to see payrolls for the last 10 years or so. Couldn't find it on google, so I fired up MAMP/Sequel Pro and tried to write a query. I wanted to see payroll for all MLB teams for 2008 (later I'd want to combine 2000-2009 or so). Here's my code:
sum(salary) AS PAYROLL
GROUP BY teamID
ORDER BY PAYROLL Desc
Didn't work…no error, but no output. What am I doing wrong? And how would I get 2000-2009 figures?