title: SQLAlchemy, MySQL, and python - how should I handle boolean?
body: <p>I have a Pyramid application that I am using with SQLAlchemy and MySQL.  For database fields that I wanted to treat as boolean, I've been using a "BIT" data type on the SQLAlchemy side, and BIT(1) on the MySQL side.</p>
  
  <p>This had all been working fine, but I was checking some newly updated code on my webhost and their version of phpMyAdmin is newer than the one I'm using locally; I was browsing a table that has a BIT field and on the newer phpMyAdmin none of the data appears - it's just blank.  On my local instance BIT fields display as 0 or 1.  If I tried to inline edit the hosted phpMyAdmin it wouldn't take any values I tried.  I did try my application code and it appears to be able to toggle the true/false values just fine.</p>
  
  <p>The got me wondering - with this setup should I be approaching it differently? SQLAlchemy does support Boolean, which seems like it would be more intuitive and appropriate, should I use that and set the MySQL fields to TINYINT instead? </p>
  
  <p>What is the conventionally accepted way to handle booleans between SQLAlchemy and MySQL?</p>