Samuel R. Neff wrote:
Eric,

Sorry if this is obvious to everyone else but not to me.. what exactly is
cursor()?  I don't see it anywhere in the C API and the wrapper I'm using
(SQLite .NET) doesn't have any corresponding method.

A cursor is the thing that you use to run your queries. Eg in Python's wrappers you import the wrapper (library, module) Connections to the database and create cursors on those Connections to do the actual work.

import sqlite3
conn=sqlite3.Connection(dbname)
crsr=conn.cursor()
crsr.execute("select * trom table")
result_set=crsr.fetchone()
...
result_set=crsr.fetchall()

and so on. SQLite cursors can only move forward in the result set. AIUI cursors in some older/bigger databases can move in either direction.

FWIW it looks like calling cursor() takes ~1.9us on my machine with Python2.5, sqlite3, disk file with schema of "create table t(a,b,c)".

Martin

-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to