[python-sybase] How to deal with DatabaseError

Andrew McNamara andrewm at object-craft.com.au
Thu Jul 20 00:26:25 EST 2006


>Am I the only one who thinks that there's an ugly flaw in the Python
>Database API [...]

Only one? 8-)

>Are there other techniques for dealing with this flaw that I haven't
>thought of?

I've seen people use things like:

    if ...:
        from pyPgSQL import PgSQL as dbapi2
    elif ...:
        import psycopg2 as dbapi2
    elif ...:
        import sybase as dbapi2

-- 
Andrew McNamara, Senior Developer, Object Craft
http://www.object-craft.com.au/


More information about the Python-sybase mailing list