title: Create a base model class
body: <p>I'm using flask-sqlalchemy.
  I currently declare my models using:</p>
  
  <pre><code>class MyModel(db.Model):
      __tablename__ = 'my_table'
      id = db.Column(db.Integer, primary_key=True)
      ...
  </code></pre>
  
  <p>I want to create a base model class so I will be able to declare my models like this:</p>
  
  <pre><code>class MyBase(db.Model):
      pass
  
  class MyModel(MyBase):
      __tablename__ = 'my_table'
      id = db.Column(db.Integer, primary_key=True)
      ...
  </code></pre>
  
  <p>Is it possible?
  I'm getting the following error:</p>
  
  <pre><code>InvalidRequestError: Class &lt;class 'api.models.base.base_model.BaseModel'&gt; does not have a __table__ or __tablename__ specified and does not inherit from an existing table-mapped class.
  </code></pre>
  
  <p>I would want to be able to put the tablename and all the column attributes inside my model and not inside my base class.</p>