FreeTDS User Guide: A Guide to Installing, Configuring, and Running FreeTDS
Prev | Chapter 6. How to get what works with it working | Next

# Python

| I am not a Python user myself, so the information contained in this section is a little rough. Please contact the list for more assistance or (better yet) to improve these instructions.

Install distutils if you haven't already.

    $ tar xvfz distutils-latest.tgz
    $ cd distutils
    $ python setup.py install

You can obtain the Python Sybase module here. This example uses version 0.34, the most current at the time of this writing, please adjust accordingly if using a different version.

    $ tar xvfz sybase-0.34.tgz
    $ cd sybase-0.34
    $ export SYBASE=/usr/local/freetds
    $ export CFLAGS="-DHAVE_FREETDS"
    $ export LD_LIBRARY_PATH=/usr/local/freetds/lib:${LD_LIBRARY_PATH}
    $ python setup.py install

Edit the example.py and fix the bottom stuff, freetds lacks the 110 symbols for version use 100

    $ python example.py

Prev | Home | Next
SybSQL | Up | Troubleshooting