Include pysqlite2 into Python 2.5?

Alex Martelli aleaxit at
Fri Oct 22 00:33:34 CEST 2004

Simon Brunning <simon.brunning at> wrote:

> On Thu, 21 Oct 2004 10:13:56 +0200, Gerhard Haering <gh at> wrote:
> (snip)
> > I think that a simple embedded relational database would be a good
> > thing to have in Python by default. And as Python 2.5 won't happen
> > anytime soon, there's plenty of time for developing it, getting it
> > stable, and integrating it.
> I think it's a great idea.


> > One problem I see is that even the new PySQLite will grow and try to
> > wrap much of the SQLite API that are not directly related to the
> > DB-API. If such a thing is too complicated/big for the standard
> > library, then maybe it would be better to produce a much simpler
> > PySQLite, especially for the Python standard library that leaves all
> > the fancy stuff out. My codename would be "embsql".
> I think it's important that we realise that if Python ships with a
> default database engine, its API will rapidly become the de-facto
> standard, eclipsing the DB-API if it is different in any way.

Good point.

> Which is not to say that the current DB-API should be used. There have
> been discussions elsewhere about improving and simplifying the DB-API
> - providing iterators, getting rid of all but one of the parameter
> styles, that kind of thing. Perhaps the best thing would be to agree a
> DB-API version 3.0 over on the DB SIG, then make sure that the built
> in module supports that.

Amen, hallelujah.

> > So, what would you like to see? "import sqlite", "import embsql", or
> > "pypi.install('pysqlite')" ?
> I'd like to see a package into which you could plug different SQL
> database engines, with SQLLite as the default. So, you might do:
> from sql import sql
> sqllite = sql.Engine()
> my_database = sqllite.Database('c:/mydatabese.db', 'user_id', 'password')
> But you if you were using another engine, you'd only need to change this to:
> from sql import sql
> from other_engine import other_engine
> other_database = sql.Engine(other_engine)
> my_database = other_database.Database('c:/myotherdatabese.db',
> 'user_id', 'password')
> >From there on in, ideally you wouldn't have to change *anything*.

Young and idealistic, I assume.  Care to name two more SQL engines
accepting exactly the same dialect as sqlite...?-)


More information about the Python-list mailing list