Coder Social home page Coder Social logo

Comments (8)

GoogleCodeExporter avatar GoogleCodeExporter commented on August 18, 2024
It works on Windows with the Microsoft ODBC driver and is part of the SQL 
Server unit tests.  On Linux you would be using FreeTDS I assume.  I believe 
that's where our difference lies.

Can you generate an ODBC trace on Linux?

Original comment by mkleehammer on 29 Jul 2011 at 1:12

  • Changed state: Investigating

from pyodbc.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 18, 2024
I'm getting the same 4096 limit for text fields via FreeTDS on ubuntu 10.04. I 
get the full result in tsql, but it is truncated in pyodbc. I have attacted an 
ODBC trace.

Original comment by [email protected] on 3 Aug 2011 at 7:04

Attachments:

from pyodbc.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 18, 2024
I found a way to fix it with free tds in your select statement you
must add the following to it:

SET TEXTSIZE 2147483647

so for instance it would look like: cursor.execute("SET TEXTSIZE
2147483647 select * from blah")

Original comment by [email protected] on 4 Aug 2011 at 11:47

from pyodbc.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 18, 2024
I found a way to fix it with free tds in your select statement you
must add the following to it:

SET TEXTSIZE 2147483647

so for instance it would look like: cursor.execute("SET TEXTSIZE
2147483647 select * from blah")

Original comment by [email protected] on 4 Aug 2011 at 11:47

from pyodbc.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 18, 2024
the FREETDS configuration has a set maximum on the returned size of a blob you 
can change this in the conf file but it's easier to do what's stated above

Original comment by [email protected] on 4 Aug 2011 at 11:48

from pyodbc.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 18, 2024
Looks like that worked. Thanks. I also found this stackoverflow explanation:

http://stackoverflow.com/questions/1060035/using-pyodbc-on-ubuntu-to-insert-a-im
age-field-on-sql-server/1073801#1073801

Original comment by [email protected] on 4 Aug 2011 at 1:49

from pyodbc.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 18, 2024
It looks like I am also able to fix it by switching TDSVER to 8.0 like so:

os.environ['TDSVER'] = '8.0'

Original comment by [email protected] on 4 Aug 2011 at 2:52

from pyodbc.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 18, 2024

Original comment by mkleehammer on 23 Dec 2011 at 8:13

  • Changed state: NoFix

from pyodbc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.