Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- pi@raspberrypi:~/Downloads $ tsql -C
- Compile-time settings (established with the "configure" script)
- Version: freetds v0.91
- freetds.conf directory: /etc/freetds
- MS db-lib source compatibility: no
- Sybase binary compatibility: yes
- Thread safety: yes
- iconv library: yes
- TDS version: 4.2
- iODBC: no
- unixodbc: yes
- SSPI "trusted" logins: no
- Kerberos: yes
- [MyDB]
- host = host.database.windows.net
- port = 1433
- tds version = 7.0
- client charset = UTF-8
- [FreeTDS]
- Description=FreeTDS Driver
- Driver=/usr/lib/arm-linux-gnueabihf/odbc/libtdsodbc.so
- Setup=/usr/lib/arm-linux-gnueabihf/odbc/libtdsS.so
- fileusage=1
- dontdlclose=1
- UsageCount=1
- def connect():
- con = pymssql.connect(server,username,password,database)
- return con
- if __name__ == "__main__":
- server = 'tcp:host.database.windows.net,1433'
- database = 'testdb'
- username = 'username'
- password = 'password'
- driver = 'FreeTDS'
- con = connect()
- pi@raspberrypi:~/Downloads $ python sql_connect.py
- Traceback (most recent call last):
- File "sql_connect.py", line 32, in <module>
- con = connect()
- File "sql_connect.py", line 5, in connect
- con = pymssql.connect(server,username,password,database)
- File "/usr/lib/pymodules/python2.7/pymssql.py", line 609, in connect
- raise InterfaceError, e[0]
- pymssql.InterfaceError: Connection to the database failed for an unknown reason.
- pi@raspberrypi:~/Downloads $ tsql -H host.database.windows.net -p 1433 -U username -P password -D testdb
- locale is "en_GB.UTF-8"
- locale charset is "UTF-8"
- using default charset "UTF-8"
- Default database being set to testdb
- Error 20017 (severity 9):
- Unexpected EOF from the server
- OS error 115, "Operation now in progress"
- Error 20002 (severity 9):
- Adaptive Server connection failed
- There was a problem connecting to the server
Add Comment
Please, Sign In to add comment