title: What are the options for storing Python long integers in MySQL?
body: <p>I need to represent instances of Python "Long integer" in MySQL. I wonder what the most appropriate SQL data type I should use.</p>
  
  <p>The Python documentation (v2.7) says (for numbers.Integral):</p>
  
  <blockquote>
    <p>Long integers</p>
    
    <blockquote>
      <p>These represent numbers in an unlimited range, subject to available (virtual) memory only. For the purpose of shift and mask operations, a binary representation is assumed, and negative numbers are represented in a variant of 2’s complement which gives the illusion of an infinite string of sign bits extending to the left.</p>
    </blockquote>
  </blockquote>
  
  <p>My read of the MySQL documentation suggests that BIGINT is limited to 64 bits. The DECIMAL type seems to be limited to 65 digits. I can, of course, use BLOB.</p>
  
  <p>The application needs to support very large amounts of data, but I don't know yet how big these long integers might get, nor how many of them I'm likely to see.</p>
  
  <p>I'd like to preserve the spirit of the Python long integer definition, which suggests BLOB. I'd also like to avoid re-inventing the wheel, and so I am appealing to the stackoverflow hive-mind.</p>
  
  <p>Suggestions?</p>