Hi,
I'm trying to use pyodbc on RHEL 5.3 64 bit but all my strings are
filled with garbage after position 1024. Here is an example:
import pyodbc
conn = pyodbc.connect('DRIVER={SQL
Server};UID=foo;PWD=bar;DATABASE=qux;SERVER=quux;TDS_Version=8.0')
conn.execute("select %r" % ("=" * 1030))
This is what I get back:
[('======================================================================== =========================================================================== =========================================================================== =========================================================================== =========================================================================== =========================================================================== =========================================================================== =========================================================================== =========================================================================== =========================================================================== =========================================================================== =========================================================================== =========================================================================== ===================================================\x00\x01\x00i;S+',
)]
This is the content of my /etc/odbcinst.ini:
------------------------------
[SQL Server]
Description = FreeTDS Driver
Driver = /usr/lib64/libtdsodbc.so.0
UsageCount = 1
------------------------------
When I try to do the same on Ubuntu 8.10, both 32 bit and 64 bit, I
get expected result, that is, a string of "=" 1030 character long.
On RHEL 5.3, unixodbc is 2.2.11-7.1, on Ubuntu it's 2.2.11-16build2,
what ever that means. I'm running Pyodbc 2.1.5 on Python 2.5.
Anyone has an idea on what can cause this and how it can be solved?
--
Yannick Gingras
http://ygingras.net/