MySQLdb module & error capturing

Walter Hofmann spamdropbox at
Sat Jun 30 17:17:03 EDT 2001

On Wed, 27 Jun 2001 08:25:23 +0200, Franz GEIGER <fgeiger at> wrote:
>Hi Paula,
>if you import _mysql you can catch the exceptions like so:

There is no need to import this internal module.

Just use "except MySQLdb.OperationalError"


More information about the Python-list mailing list