title: Fast, in-memory range lookup against +5M record table
body: <p>I have a database table with +5M static records in place. Simple structure: (starting int, ending int, result int). So i have an certain INT and i need to find it's corresponding result(int). Currently, the look-up table is in DB, but it needs to reside in-memory, most likely in the environment without a database access. </p>
  
  <p>My solution needs to perform this logic without a database access, in memory and super fast as I need to process 1000s of transactions per second. The size of the set is little over 50MB so I could throw the whole thing into the memory and run range look-ups against it, per this post: <a href="https://stackoverflow.com/questions/8948205/doing-a-range-lookup-in-c-sharp-how-to-implement/8949322#8949322">Doing a range lookup in C# - how to implement</a>. But I don't know how it will perform on such scale.</p>
  
  <ul>
  <li>Do I pre-load that table "on startup" ? It might take a while. </li>
  <li>Any way to load the table into some .dat file and have super efficient look-up at run time?</li>
  </ul>
  
  <p>BTW, I am on Azure, not sure if using Storage Tables helps on lookups...</p>