### I have the following python test script:

import sqlite

cx = sqlite.connect('xyz.db')

cu = cx.cursor()
cu.execute('create table t1 (a,b,c)')
cu.execute('insert into t1 values (1,2,3)')
cx.commit()

cu.execute("select * from t1")
row = cu.fetchone()
print row

### When ran, I get the ff messages:

C:/PYTHON23/pythonw.exe -u  "Z:/devpy/test/sqlite.pyw"
Traceback (most recent call last):
  File "Z:/devpy/test/sqlite.pyw", line 1, in ?
    import sqlite
  File "Z:\devpy\test\sqlite.pyw", line 3, in ?
    cx = sqlite.connect('xyz.db')
AttributeError: 'module' object has no attribute 'connect'

### What seems to be wrong? I have installed:
### pysqlite-1.1.6.win32-py2.3.exe

### Thanks. This is my first attempt at python+sqlite.

Reply via email to