view Doc/includes/sqlite3/execute_2.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 c62f6669ae22
children
line wrap: on
line source

import sqlite3

con = sqlite3.connect("mydb")

cur = con.cursor()

who = "Yeltsin"
age = 72

cur.execute("select name_last, age from people where name_last=:who and age=:age",
    {"who": who, "age": age})
print cur.fetchone()