2009 is out, and the database is disassembled by decade for the 1950’s, 1960’s, 1970’s, 1980’s, 1990’s, and 2000’s. You can also download the full thing also. Check out the links below.
Please help me with my bandwidth costs or just buy me a beer.
I have compiled the Retrosheet Baseball Data into a mysql database using Tangotiger.net’s Wiki. I was asked to do this for my brother, and I figured that the rest of the baseball community might not want have a brother as technically savvy. Please feel free to download the 400 MB file in .gz format. I am a Linux man sorry all you people wanting zip there are plenty of programs that will allow you to extraxt .gz file. Once you unzip the file from it’s 400 MB size to it’s 4.9 GB flat file size you will need to import it with the following command.
mysql -uusername -ppassword -hlocalhost retrosheet < retrosheet.sql
Or something of that nature depending on your setup.
I am allowing you to download this database for free with the asking that you help my bandwidth cost by donating below.
Click Here to download the Full Retrosheet database .
Click Here to download the 1950’s Retrosheet database.
Click Here to download the 1960’s Retrosheet database.
Click Here to download the 1970’s Retrosheet database.
Click Here to download the 1980’s Retrosheet database.
Click Here to download the 1990’s Retrosheet database.
Click Here to download the 2000’s Retrosheet database.
Check out my Pitch FX download page also.
#1 by Ben at December 9th, 2009
This doesn’t include 2009, does it? Will you be adding that anytime soon? Thanks!
#2 by Darrell at December 14th, 2009
2009 should be up before the 1st of the year. they released the new data but have errors so I am waiting.
#3 by Nick Steiner at December 22nd, 2009
Darrel, I love you.
#4 by Derek Carty at January 3rd, 2010
This is awesome, Darrell. Have you posted an explanation file for the fields that aren’t in the usual Retrosheet files? Fields 97 and beyond? I can guess at some of them but others I’m not entirely sure about.
Thanks!
#5 by Darrell at January 4th, 2010
I will have to get my brother to look into this for you. He uses the database, I just make the bastard child.
#6 by Derek Carty at January 8th, 2010
Thanks, Darrell.
#7 by Derek Carty at January 8th, 2010
Found it, Darrell. Never mind, and thanks again for putting this together.
http://chadwick.sourceforge.net/chapter1.html#cwevent-expanded-event-descriptor
#8 by Rich at January 3rd, 2010
I recently insalled mysql 5.1 and am attempting to run the command to import the SQL script, however I keep getting an error using the syntax above. My database is called “baseball” and I’m using the root userid. Any help in importing would be greatly appreciated.
#9 by Darrell at January 4th, 2010
Rich,
The top 20 lines of the retrosheet file has a USE ‘retrosheet’ line. You need to change that to ‘baseball’ or remove it all together and put baseball in your connection string. The file is huge so this might not be the best way. 4 GB in notepad doesn’t fly. It is a pain in VI also.
mysql -uusername -ppassword -hlocalhost baseball < retrosheet.sql
The other way of doing it is to import the entire database as retrosheet database. When it is done turn off the mysql database and copy the database directory from retrosheet to baseball. Start mysql, and connect to it with your favorite editor. If the database baseball is there drop database retrosheet. Seems like few steps, but I do it this way when playing around with it.
Darrell
#10 by Rich at January 4th, 2010
Good to know. I dropped the baseball database and created the retrosheet database.
So here is the syntax I’m using for the import:
mysql -uroot -pmahler -hlocalhost retrosheet < retrosheet.sql
The sql is saved on my C: drive and in the bin folder where mysql.exe is stored.
Still getting a syntax error. Can you see the error in my command line? If not, I wonder if it's my install.
Thanks!
#11 by Stephen Varga at February 3rd, 2010
Thanks a lot for this, really awesome! I am doing a thesis project that uses this data and I’m really excited not to have to recompile all this again with the 2009 data. Is playoff data included in your database?