[IronPython] How to connect to SQL Server 2008?

Matthew Wilson matt at tplus1.com
Thu May 27 16:54:18 CEST 2010


I want to connect with IronPython to SQLServer 2008.  I found some SAS
code (SAS is another programming language) that uses OLEDB and I have a
connection string with the server name and credentials.

In IronPython in Action, there's an example of how to connect to a
Postgresql database, and that example has this section:

    >>> import clr
    >>> clr.AddReference('Npgsql')
    >>> import Npgsql as pgsql
    >>> connection = pgsql.NpgsqlConnection('....')

What do I need to use for my clr.AddReference and my import?

Thanks in advance.

Matt

    




More information about the Ironpython-users mailing list