mxODBC module

ekw1 at my-deja.com ekw1 at my-deja.com
Thu Jul 6 01:20:33 EDT 2000


I've installed mxODBC along with mxDateTime for Python 1.5.2 on
Windows98.  I'm getting errors when I try to connect to a MySQL 3.23.19
database (which I've used MyODBC to set up ODBC connection to it).

When I try to use ODBC.Windows, I get this error:
>>> import ODBC.Windows
>>> db = ODBC.Windows.Connect("DSN_name")
Traceback (innermost last):
  File "<pyshell#15>", line 1, in ?
    db = ODBC.Windows.Connect("PyNotes")
NotSupportedError: ('S1C00', 0, "[TCX][MyODBC]MySQL can't use
transactions", 4226)

And I can't even import ODBC.MySQL:
>>> import ODBC.MySQL
Traceback (innermost last):
  File "<pyshell#13>", line 1, in ?
    import ODBC.MySQL
  File "C:\Program Files\Python\Lib\ODBC\MySQL\__init__.py", line 7, in
?
    from mxODBC import *
ImportError: No module named mxODBC

mxODBC is on the same directory level as MySQL, but it can't be found.

I don't know what the differences/advantages to either method would be,
but can anyone help me get this working?  I am able to connect to the
MySQL DB via Java and JDBC-ODBC and program it successfully, but would
like to get Python connected as well.  Thanks for any help.

ekw


Sent via Deja.com http://www.deja.com/
Before you buy.



More information about the Python-list mailing list