title: Table isn't available even though Flask-SQLAlchemy create_all was called
body: <p>I'm trying to fetch records from my database, but I get</p>
  
  <pre><code>OperationalError: (sqlite3.OperationalError) no such table: driver
  </code></pre>
  
  <p>even though I defined the model and called <code>db.create_all()</code>. Why doesn't this work?</p>
  
  <pre><code>from flask import Flask
  from flask_sqlalchemy import SQLAlchemy
  
  app = Flask(__name__)
  app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:////tmp/test.db'
  db = SQLAlchemy(app)
  db.create_all()
  
  class Driver(db.Model):
      id = db.Column(db.Integer, primary_key=True)
  
  @app.route('/')
  def index():
      result = Driver.query.all()
      return render_template('index.html', result=result)
  </code></pre>