I could connect to the server only with Windows, but on OS X I got the following error message:
stagger$ python msqldb.py
Traceback (most recent call last):
File "msqldb.py", line 3, in ?
con = pymssql.connect(host='192.168.1.1',user='user',password='password',database='tempdb')
File "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-packages/pymssql.py", line 328, in connect
con = _mssql.connect(dbhost, dbuser, dbpasswd)
_mssql.error: DB-Lib error message 20009, severity 9:
Server is unavailable or does not exist.
In the end I just had to specify the (default) port number too, so the connect line in python looks like this:
con = pymssql.connect(host='192.168.1.1:1433',user='user',password='password',database='tempdb')
Thought this might save someone some time.
Daniel
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I could connect to the server only with Windows, but on OS X I got the following error message:
stagger$ python msqldb.py
Traceback (most recent call last):
File "msqldb.py", line 3, in ?
con = pymssql.connect(host='192.168.1.1',user='user',password='password',database='tempdb')
File "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-packages/pymssql.py", line 328, in connect
con = _mssql.connect(dbhost, dbuser, dbpasswd)
_mssql.error: DB-Lib error message 20009, severity 9:
Server is unavailable or does not exist.
In the end I just had to specify the (default) port number too, so the connect line in python looks like this:
con = pymssql.connect(host='192.168.1.1:1433',user='user',password='password',database='tempdb')
Thought this might save someone some time.
Daniel