[DB-SIG] Multiple Statements

Federico Di Gregorio fog@initd.org
28 May 2002 23:44:08 +0200


--=-MnLJIhQ3DNmK3RwomwJe
Content-Type: text/plain; charset=ISO-8859-15
Content-Transfer-Encoding: quoted-printable

Il mar, 2002-05-28 alle 21:36, Gerhard H=E4ring ha scritto:
> >From my interpretation of the DB-API specfication, it's not possible to
> put multiple SELECT statements into one execute() call. That's what
> executemany() with .nextset() is for, right? Do I really have to
> support this in a DB-API compliant module, though?

no. .nextset() is _not_ for multiple select. at least that's what was
decided after some discussion about 1y ago.

> What about multiple non-SELECT SQL statements seperated by ; in an
> execute() call (read: INSERT, UPDATE, PRAGMA).  Would this be valid?
> Again I personally would use executemany(). I'm just wondering if I have
> to have to account for it in an execute() call.

don't really know. psycopg will allow that and even to end the list with
a select but i don't know about other adapters.

--=20
Federico Di Gregorio
Debian GNU/Linux Developer & Italian Press Contact        fog@debian.org
INIT.D Developer                                           fog@initd.org
  We are all dust, Saqi, so play the lute
                    We are all wind, Saqi, so bring wine. -- Omar Khayam

--=-MnLJIhQ3DNmK3RwomwJe
Content-Type: application/pgp-signature; name=signature.asc

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQA88/onvcCgrgZGjesRAsHKAKCylWvjBWkiHLgzu9vOaGO2LSOXkgCgyLCQ
96QRzciJGCrZpFruDruvFA4=
=jnNl
-----END PGP SIGNATURE-----

--=-MnLJIhQ3DNmK3RwomwJe--