1. #1
    Inspirited
    Inspirited's Avatar SBR PRO
    Join Date: 06-26-10
    Posts: 1,783
    Betpoints: 17840

    How do you store your odds?

    For each game there will be something like this:

    10/11,10:55,AM,+5,+100,-5,-110
    10/11,10:56,AM,+5,+100,-5,-113
    10/11,10:57,AM,+5,+100,-5,-110
    10/11,10:58,AM,+5,+100,-5,-113
    etc...

    You'll have several of these for each sportsbook. Then you'll have all the games.

    Right now I'm thinking of having separate csv files for each game.

    Within each file I'd like to line up the odds from different sportsbooks by time, but they don't put out odds at the same time so I was thinking of putting each minute in one column and then just fill in the odds. Doing it like this will take up more space. I don't know maybe I'll try to think of a way to search without having to actually do this minute by minute.



    Ah, maybe I could search for the datetime, and if it's not present decrement the datetime until a datetime is present. From here I can get the odds next to the datetime, and they should be the same odds available at the time originally wanted.
    Last edited by Inspirited; 10-04-11 at 02:53 AM. Reason: found a possible solution to the search problem

  2. #2
    podonne
    podonne's Avatar Become A Pro!
    Join Date: 07-01-11
    Posts: 104

    I keep my database in a similar form, just put all the records in a single table in Access or SQL\MySQL like this:

    SportsbookID
    GameID
    DateTimeRecorded
    AwaySpread
    AwayCost
    HomeSpread
    HomeCost

    Then, to pull at a particular time you just run a query like this:
    Code:
     
    select * from odds_table where DateTimeRecorded<=[now] and book=[bookid]
    to get the most recent odds record for a given book

Top