[DB-SIG] PEP249 - Proposed change to DB-API 2.0
Stuart Bishop
stuart@sharinga.com
Thu, 3 May 2001 14:57:04 +1000
> > [Making the DB API interface handle multiple paramstyles]
> >
> > How about specifying a single 'python meta' -style. So the module
> > writers would support the database native format, and the Python DB-Api
> > format, from which a conversion to native format would exist. I spent
> > maybe 2 minutes thinking about it, so maybe this is not feasible, just a
> > thought...
>
> This is not necessarily efficient, e.g. MySQL and Postgresql are
> just fine with wrapping data up in the SQL statement itself,
> but e.g. many ODBC drivers pass in data using column binding and
> only parse the SQL once (parsing and checking for correctness
> takes a long time...) !
>
> I'd rather leave it at the current open state of affairs. People who
> want to use a generic interface can use wrappers or Chris' dbhelper.py
> module if they want to.
If there is need of a PEP, it would be to have one of the wrappers
formalized and included in the standard python distribution. Adding
Gadfly in as the default driver would be an added bonus for a variety
of reasons, not the least oneupmanship with most other languages :-)