[IronPython] MySQL and Iron Python

Ian Hobson ian at ianhobson.co.uk
Tue Jul 20 20:23:07 CEST 2010


Hi Vernon,

Sorry for my previous post - it slipped out as I was trying to convert 
your tests to use a real user, server and password.

The full result of running the test batch job is

D:\work\Moschatel\adodbapi\tests>runtests.bat

D:\work\Moschatel\adodbapi\tests>if "" == "" goto skip_1

D:\work\Moschatel\adodbapi\tests>if not "python" == "" goto skip_python

D:\work\Moschatel\adodbapi\tests>Echo on

D:\work\Moschatel\adodbapi\tests>echo .
.

D:\work\Moschatel\adodbapi\tests>echo .
.

D:\work\Moschatel\adodbapi\tests>del *.pyc

D:\work\Moschatel\adodbapi\tests>echo .
.

D:\work\Moschatel\adodbapi\tests>REM unit test

D:\work\Moschatel\adodbapi\tests>call python adodbapitest.py
2.6.5 (r265:79096, Mar 19 2010, 21:48:26) [MSC v.1500 32 bit (Intel)]
adodbapi v2.3.0
adodbapitestconfig.py v 2.3.0
     ...Testing MS-SQL login...
(-2147352567, 'Exception occurred.', (0, u'Microsoft OLE DB Provider for 
SQL Ser
ver', u'Cannot open database "Northwind" requested by the login. The 
login faile
d.', None, 0, -2147467259), None)
     ...Testing MySql login...
(-2147352567, 'Exception occurred.', (0, u'Microsoft OLE DB Provider for 
ODBC Dr
ivers', u'[Microsoft][ODBC Driver Manager] Data source name not found 
and no def
ault driver specified', None, 0, -2147467259), None)
  Unit tests for adodbapi version 2.3.0
Default Date Converter is <adodbapi.pythonDateTimeConverter object at 
0x02386310
 >
....................................................
----------------------------------------------------------------------
Ran 52 tests in 1.895s

OK
Changed dateconverter to
<adodbapi.pythonTimeConverter object at 0x02794F70>
....................................................
----------------------------------------------------------------------
Ran 52 tests in 1.907s

OK

D:\work\Moschatel\adodbapi\tests>echo .
.

D:\work\Moschatel\adodbapi\tests>echo .
.

D:\work\Moschatel\adodbapi\tests>REM generic test

D:\work\Moschatel\adodbapi\tests>call python test_adodbapi_dbapi20.py
This module depends on the dbapi20 compliance tests created by Stuart Bishop
(see db-sig mailing list history for info)
adodbapi v2.3.0
Tested with dbapi20 1.12
     ...Testing MS-SQL login...
(-2147352567, 'Exception occurred.', (0, u'Microsoft OLE DB Provider for 
SQL Ser
ver', u'Cannot open database "Northwind" requested by the login. The 
login faile
d.', None, 0, -2147467259), None)

D:\work\Moschatel\adodbapi\tests>echo .
.

D:\work\Moschatel\adodbapi\tests>echo .
.

D:\work\Moschatel\adodbapi\tests>pause Testing complete
Press any key to continue . . .

D:\work\Moschatel\adodbapi\tests>

Googling "Data source name not found and no default driver specified" 
has not been any help!

Regards

Ian



On 20/07/2010 19:05, Vernon Cole wrote:
> I use MySQL as one of the basic tests for adodbapi, so I can say that 
> it works pretty well for me.
> What obstacle do you hit?
> --
> Vernon Cole
>
> On Tue, Jul 20, 2010 at 11:52 AM, Ian Hobson <ian at ianhobson.co.uk 
> <mailto:ian at ianhobson.co.uk>> wrote:
>
>     Hi all,
>
>     How can I (a nube) read a MySQL database using Iron Python?
>     (windows 7 and 2008 Server).
>
>     Any method will do, so long as it works. :)
>
>     I've tried adodbapi and mysqldb and mysqlconnector - and always
>     hit an obstacle I can't get round.
>
>     Regards
>
>     Ian
>
>
>     _______________________________________________
>     Users mailing list
>     Users at lists.ironpython.com <mailto:Users at lists.ironpython.com>
>     http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>
>
>
> _______________________________________________
> Users mailing list
> Users at lists.ironpython.com
> http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>    
>
>
>
> No virus found in this incoming message.
> Checked by AVG - www.avg.com
> Version: 9.0.839 / Virus Database: 271.1.1/3017 - Release Date: 07/20/10 07:36:00
>
>    

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20100720/9da881f9/attachment.html>


More information about the Ironpython-users mailing list