# Source for Sports Statistics

**URL:** <https://boards.straightdope.com/t/source-for-sports-statistics/616701>\
**Category:** The Game Room\
**Created:** [March 24, 2012, 6:14pm UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701 "2012-03-24T18:14:08Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![yearofglad](https://avatars.discourse-cdn.com/v4/letter/y/b782af/32.png) [@yearofglad](https://boards.straightdope.com/u/yearofglad)\
**Post date:** [March 24, 2012, 6:14pm UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701/1 "2012-03-24T18:14:08Z")

</div>

ESPN, etc., always have crazy stats - yesterday Kevin Durant and Russell Westbrook were the first duo to each score 40 points in a game twice in the same season since I don’t know when.

I understand that keeping stats like that are easy, but how are they FOUND? How would you search for such a statistic? Are there database programs that will accepts such specific queries, given that such statistics come in virtually all flavors imaginable. It’s hard for me to imagine that such a flexible method exists.

Any insights?

---

<div class="post-metadata">

**Author:** ![Ace309](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/ace309/32/1050_2.png) [@Ace309](https://boards.straightdope.com/u/Ace309)\
**Post date:** [March 24, 2012, 7:46pm UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701/2 "2012-03-24T19:46:28Z")

</div>

I can’t speak to basketball specifically, but I often snag my baseball stats from [Baseball Reference](http://baseball-reference.com). It has a searchable database that’s extremely flexible.

I know they run sites for other sports as well.

---

<div class="post-metadata">

**Author:** ![Colibri](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/colibri/32/1841_2.png) [@Colibri](https://boards.straightdope.com/u/Colibri)\
**Post date:** [March 24, 2012, 8:03pm UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701/3 "2012-03-24T20:03:48Z")

</div>

Moved to the Game Room from GQ.

Colibri  
General Questions Moderator

---

<div class="post-metadata">

**Author:** ![RealityChuck](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/realitychuck/32/195_2.png) [@RealityChuck](https://boards.straightdope.com/u/RealityChuck)\
**Post date:** [March 24, 2012, 8:13pm UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701/4 "2012-03-24T20:13:42Z")

</div>

Most broadcast sports use the [Elias Sports Bureau](http://en.wikipedia.org/wiki/Elias_Sports_Bureau). They’ve been gathering sports statistics for almost a century, and have every sports database you can imagine.

I assume someone from Elias is in the Broadcast booth with a computer logged in to the database. He can search for anything that happens in the game. He also prepares for particular records to be broken and has them all ready to go if necessary. If, say, a pitcher has won his previous two games, they will look up instances where that pitcher had won two games in a row before the game starts.

---

<div class="post-metadata">

**Author:** ![Omniscient](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/omniscient/32/3290_2.png) [@Omniscient](https://boards.straightdope.com/u/Omniscient)\
**Post date:** [March 24, 2012, 10:42pm UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701/5 "2012-03-24T22:42:29Z")

</div>

> [@yearofglad](#):
>
> Are there database programs that will accepts such specific queries, given that such statistics come in virtually all flavors imaginable. It’s hard for me to imagine that such a flexible method exists.

Yup, it’s called SQL. Almost every business in the world uses it. It’s exactly how Stats Inc, Elias and ESPN Stats find this things. Something interesting happens, then the database professionals/analysts start punching queries into the database of past results. Those past results are organized and cross referenced in a way to make it easy to search for details like that.

Here’s a sample of what the SQL code would look like for the case mentioned in the OP. Syntax varies between software brands, but it’s all pretty similar.

SELECT \* FROM NBA\_GAME\_RESULTS WHERE playerScore \>= 40 GROUP BY gameDate, playerTeam

That’s overly simplified and you’d have to sift through the results to find cases where the gameDeate is repeated but the Query can be expanded to do that work for you. Without knowing the Schema and straining my brain I’m not going to try and do that./

---

<div class="post-metadata">

**Author:** ![mcgato](https://avatars.discourse-cdn.com/v4/letter/m/ac8455/32.png) [@mcgato](https://boards.straightdope.com/u/mcgato)\
**Post date:** [March 25, 2012, 1:22am UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701/6 "2012-03-25T01:22:20Z")

</div>

[This is a link to a database of everything Olympics](http://www.sports-reference.com/olympics/). There are links in the upper right to other sports, including baseball, football, hockey, and basketball. The Olympic one is silly in the amount of info it has, including birth, death, results, name spelled in native language, etc.

---

<div class="post-metadata">

**Author:** ![Duke](https://avatars.discourse-cdn.com/v4/letter/d/e8c25b/32.png) [@Duke](https://boards.straightdope.com/u/Duke)\
**Post date:** [March 25, 2012, 2:10am UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701/7 "2012-03-25T02:10:43Z")

</div>

> [@Omniscient](#):
>
> Here’s a sample of what the SQL code would look like for the case mentioned in the OP. Syntax varies between software brands, but it’s all pretty similar.
> 
> SELECT \* FROM NBA\_GAME\_RESULTS WHERE playerScore \>= 40 GROUP BY gameDate, playerTeam
> 
> That’s overly simplified and you’d have to sift through the results to find cases where the gameDeate is repeated but the Query can be expanded to do that work for you. Without knowing the Schema and straining my brain I’m not going to try and do that./

That’s close. Here’s how I’d do it:

SELECT Player\_Score, Team\_name, Game\_ID, Count(Player\_Name)  
FROM tblNBA\_GAME\_RESULTS  
GROUP BY tblNBA\_GAME\_RESULTS.Player\_Score, tblNBA\_GAME\_RESULTS.Game\_ID, tblNBA\_GAME\_RESULTS.Team\_name  
HAVING (((tblNBA\_GAME\_RESULTS.Player\_Score)\>=40) AND ((Count(Player\_Name))\>1));

That should do it. I tested it on a database I’m working on and it worked correctly, at least.

---

<div class="post-metadata">

**Author:** ![mnemosyne](https://avatars.discourse-cdn.com/v4/letter/m/c4cdca/32.png) [@mnemosyne](https://boards.straightdope.com/u/mnemosyne)\
**Post date:** [March 25, 2012, 3:28am UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701/8 "2012-03-25T03:28:55Z")

</div>

For simplicity, often times news reporters are given a media guide every year with the historical statistics for the team they report on. I know Ive seen news articles about them here and there - Mike Boone of the Montreal Gazette has writen about it for sure.

---

<div class="post-metadata">

**Author:** ![yearofglad](https://avatars.discourse-cdn.com/v4/letter/y/b782af/32.png) [@yearofglad](https://boards.straightdope.com/u/yearofglad)\
**Post date:** [March 25, 2012, 3:39pm UTC](https://boards.straightdope.com/t/source-for-sports-statistics/616701/9 "2012-03-25T15:39:36Z")

</div>

> [@Duke](#):
>
> That’s close. Here’s how I’d do it:
> 
> SELECT Player\_Score, Team\_name, Game\_ID, Count(Player\_Name)  
> FROM tblNBA\_GAME\_RESULTS  
> GROUP BY tblNBA\_GAME\_RESULTS.Player\_Score, tblNBA\_GAME\_RESULTS.Game\_ID, tblNBA\_GAME\_RESULTS.Team\_name  
> HAVING (((tblNBA\_GAME\_RESULTS.Player\_Score)\>=40) AND ((Count(Player\_Name))\>1));
> 
> That should do it. I tested it on a database I’m working on and it worked correctly, at least.

Thanks - that’s exactly what I was curious about. I know about Elias, etc., and SQL, but couldn’t quite piece together how such a query would work. I don’t know SQL but can make sense of the queries you guys posted.

Thanks.
