[DB-SIG] General DB Error Handling
Matthew T. Kromer
matt@zope.com
Wed, 26 Jun 2002 13:42:54 -0400
Robert Theiss wrote:
>All,
>
>I am writing a python script to connect to an informix
>database using informixdb.py. I am new to python and
>object oriented programmign in general, but I have
>good experience using embedded SQL and C .
>
>What I would like to do is trap any error returned
>from the database, so I can exit the program
>gracefully. A sample output is shown below, when I
>intentionally generate an SQL error.
>
>[bobt@monza:/service/bobt] > python InfTest.py
>WARNING: Python C API version mismatch for module
>_informixdb:
> This Python has API version 1010, module _informixdb
>has version 1007.
>WARNING: Python C API version mismatch for module dbi:
> This Python has API version 1010, module dbi has
>version 1007.
>20020626
>
>
Uh, I'd recompile your modules first! Looks like you're using modules
built with Python 1.5.2 with Python 2.1.
--
Matt Kromer
Zope Corporation http://www.zope.com/