发布时间:2019-08-27 08:03:41编辑:auto阅读(1857)
安装pymssql需要的包:
freetds(http://www.filewatcher.com/m/freetds-0.82.tar.gz.1596755-0.html)
setuptools(https://pypi.python.org/pypi/setuptools)
pymssql(https://pypi.python.org/pypi/pymssql/)
安装步骤:
1. 安装freetds
#tar zxvf freetds-0.82.tar.gz
#cd freetds-0.82
#./configure --prefix=/usr/local/freetds --with-tdsver=8.0 --enable-msdblib --enable-dbmfix --with-gnu-ld --enable-shared --enable-static
#make && make install
#echo "/usr/local/freetds/lib" >> /etc/ld.so.conf.d/freetds.conf
#ldconfig -v
2. 安装setuptools
#tar zxvf setuptools-3.5.1.tar.gz
#cd setuptools-3.5.1
# python setup.py install
3. 安装pymssql
#tar zxvf pymssql-2.1.0.tar.gz
#cd pymssql-2.1.0
#python setup.py install
注:如果不安装freetds,会报如下错误:
error: command 'gcc' failed with exit status 1 |
上一篇: Python 例题 -- 巴比伦平方根算
下一篇: python 2.7后的字符串赋值
48150
46866
37784
35089
29623
26272
25211
20248
19889
18368
6021°
6719°
6204°
6183°
7296°
6136°
6254°
6727°
6703°
8082°