- attached pyodbc port fix.patch
pyodbc adapter doesn't support host:port syntax
Issue #634
resolved
When migrating from adodbapi to pyodbc, I ran into a connection failure with the connect URL including a port number:
from sqlalchemy import * global_connect( 'mssql://localhost:1234/testdb' ) default_metadata.engine.connect()
The last statement will fail when using pyodbc, but works fine in adodbapi.
The attached patch addresses the issue and is backward compatible, allowing host,port and host:port syntax (host,port is handled the same way it currently is, where the entire string is parsed as the hostname).
Comments (4)
-
Account Deleted -
Account Deleted - attached mssql-port-fix.patch
another suggested patch to handle host,port assembly.
-
Account Deleted I just added a second revision to the patch (supercedes the first patch) that handles the common functionality in the parent class.
-
Account Deleted - changed status to resolved
(original author: ram) Committed a simple fix in 2867
- Log in to comment
proposed patch