Pytds - Microsoft SQL Server database adapter for Python

Pytds is the top to bottom pure Python TDS implementation, that means cross-platform, and no dependency on ADO or FreeTDS. It supports large parameters (>4000 characters), MARS, timezones, new date types (datetime2, date, time, datetimeoffset). Even though it is implemented in Python performance is comparable to ADO and FreeTDS bindings.

It also supports Python 3.

Contents

Connection to Mirrored Servers

When MSSQL server is setup with mirroring you should connect to it using two parameters of pytds.connect(), one parameter is server this should be a main server and parameter failover_partner should be a mirror server. See also MSDN article.

Indices and tables