sphinx_django/db_script.py
author amit
Thu, 30 Sep 2010 11:36:30 +0530
changeset 0 54f784230511
permissions -rw-r--r--
Initial commit of django based commenting system for sphinx. Already has most of the boiler plate code.

from sqlalchemy import *

db = create_engine('sqlite:///test.db')

db.echo = False  # Try changing this to True and see what happens

metadata = MetaData(db)

chapter = Table('Chapter', metadata,
    Column('id', Integer, primary_key=True),
    Column('name', String(40)),
)
chapter.create()

i = chapter.insert()
i.execute(name='basic_func')