I use Mac (OS X 10.11.5). I want to install module pymssql
for python.
In Terminal.app
, I input sudo -H pip install pymssql
, pip
The top voted solution did not work for me as brew did not link the older version of freetds on its own. I did this to solve the problem:
brew unlink freetds;
brew install freetds@0.91;
brew link --force freetds@0.91
All the solutions above work well . Just one word of caution , the setup.py for pymssql pip install pymssql expects that Homebrew has installed Freetds at /sw
if sys.platform == 'darwin':
fink = '/sw'
This was not the case in my machine so I had to use the work around here :
I was able to work around this by reverting to an older version of FreeTDS through Homebrew before running the pip install.
brew unlink freetds; brew install homebrew/versions/freetds091
The solution was found by andrewmwhite at: https://github.com/pymssql/pymssql/issues/432
This worked for me on mac:
pip install cython
then
pip install git+https://github.com/pymssql/pymssql.git
Found Detailed and simple answer with step by step installation of pymssql on http://gree2.github.io/python/setup/2017/04/19/python-instal-pymssql-on-mac.
brew unlink freetds; brew install homebrew/core/freetds091
brew link --force freetds@0.91
pip install pymssql
"brew install homebrew/python/pymssql" also worked but will install older 2.1.1 as of today.