view Doc/includes/sqlite3/executescript.py @ 48178:cf331fef3293 legacy-trunk

Silence warnings under -3 triggered by wsgiref.
author Brett Cannon <bcannon@gmail.com>
date Mon, 04 Aug 2008 21:30:53 +0000
parents 9e1529bf0442
children
line wrap: on
line source

import sqlite3

con = sqlite3.connect(":memory:")
cur = con.cursor()
cur.executescript("""
    create table person(
        firstname,
        lastname,
        age
    );

    create table book(
        title,
        author,
        published
    );

    insert into book(title, author, published)
    values (
        'Dirk Gently''s Holistic Detective Agency',
        'Douglas Adams',
        1987
    );
    """)