[DB-SIG] DB-API 1.1
M.-A. Lemburg
mal@lemburg.com
Fri, 05 Jun 1998 10:42:56 +0200
> > > > Module Interface
> > > >
> > > > The database interface modules should typically be named with
> > > > something terminated by db.
> > >
> > > Why?
> > >
> >
> > Agreed, this really isn't necessary.
>
> I used "db" to indicate that it was DBI compliant, rather than a
> proprietary interface.
We could have a nice icon for that... DB-API 1.x compatible
or something... ;-)
> > > > Existing examples are: oracledb,
> > > > informixdb, and pg95db. These modules should export several names:
> > > > modulename(connection_string_or_tuple)
> > >
> > > Why use the module name? Why not some descriptive name
> > > like: 'Connect'?
> > >
> >
> > Historical reasons, i.e. no good reason.
>
> Well, "good" is subjective. The original reason, which hasn't changed, is
> that the constructor must be manipulated by code that understand what
> RDBMSs are available, not be generic code. The rest of the API is
> intended to be used by generic code.
Having it named 'Connect' makes porting applications much
easier: all you have to do is change the import (in the ideal
case).
--
Marc-Andre Lemburg
----------------------------------------------------------------------
| Python Pages: http://starship.skyport.net/~lemburg/ |
-------------------------------------------------------